Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
W4OS OpenSimulator Interface
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Package Registry
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenSimulator
W4OS OpenSimulator Interface
Compare Revisions
6337036ffb9208d1962b34551ed51662d8027a41...f68a9913d7ba8745cbb242ae5df74df1f6b0de3f
Source
f68a9913d7ba8745cbb242ae5df74df1f6b0de3f
Select Git revision
...
Target
6337036ffb9208d1962b34551ed51662d8027a41
Select Git revision
Compare
Commits (2)
Update readme files
· f534dec8
Gudule Lapointe
authored
Jun 24, 2020
f534dec8
0.11.0
· f68a9913
Gudule Lapointe
authored
Jun 28, 2020
* added shortcode and dashboard widget to show last users
f68a9913
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
71 additions
and
24 deletions
+71
-24
CHANGELOG.md
CHANGELOG.md
+3
-0
README.md
README.md
+19
-13
admin/dashboard.php
admin/dashboard.php
+8
-0
includes/shortcodes.php
includes/shortcodes.php
+28
-0
readme.txt
readme.txt
+12
-10
w4os.php
w4os.php
+1
-1
No files found.
CHANGELOG.md
View file @
f68a9913
### 0.11.0
*
added shortcode and dashboard widget to show last users
### 0.10.2
*
fixed https://github.com/GuduleLapointe/w4os/issues/1 undefined constant. Thx djphil
*
merged latest translations from https://git.magiiic.com/opensimulator/w4os-translations
...
...
README.md
View file @
f68a9913
...
...
@@ -5,36 +5,42 @@ WordPress interface for OpenSimulator
## Description
The first ready to use WordPress interface for OpenSimulator. Provides user
registration and basic grid info. See enabled features below and ROADMAP file
for upcoming functionalties.
registration and basic grid info. See current Features below, and Roadmap
section in readme.txt for upcoming functionalties.
This README.md contains a brief introduction and information specific to the git
development version. Complimentary details in WordPress standard readme.txt
file.
## Features
*
**Grid info**
:
`[gridinfo]`
shortcode and admin dashboard widgets
*
**Grid status**
:
`[gridstatus]`
shortcode and admin dashboard widgets
*
**Avatar creation**
:
-
**Grid info**
:
`[gridinfo]`
shortcode and admin dashboard widgets
-
**Grid status**
:
`[gridstatus]`
shortcode and admin dashboard widgets
-
**Avatar creation**
:
-
`[w4os_profile]`
shortcode can be inserted in any page
-
Avatar tab in account dashboard on WooCommerce websites
-
Choose avatar look from default models
*
Avatar and website passwords are synchronized
*
**Reserved names**
: avatar whose first name or last name is "Default",
-
Avatar and website passwords are synchronized
-
**Reserved names**
: avatar whose first name or last name is "Default",
"Test", "Admin" or the pattern used for appearance models are disallowed for
public (such avatars must be created by admins from Robust console)
*
**OpenSimulator settings page**
:
-
**OpenSimulator settings page**
:
-
grid name, login uri and database connection settings
-
naming scheme of default models
-
exclude models from grid stats
## Install from git repository
*
Download the latest pagkage https://git.magiiic.com/opensimulator/w4os/-/archive/master/w4os-master.zip
*
Unzip it, rename
`w4os-master`
as
`w4os`
and move it inside
`wp-content/plugins/`
*
Download the latest pagkage
https://git.magiiic.com/opensimulator/w4os/-/archive/master/w4os-master.zip
*
Unzip it, rename
`w4os-master`
to
`w4os`
, move it inside
`wp-content/plugins/`
*
Activate from your plugins page
*
Go to admin menu OpenSimulator > Settings to enter your grid details
To receive updates, install
[
GitHub Updater
](
https://github.com/afragen/github-updater
)
(temporarily, if you get a PCLZIP_ERR_BAD_FORMAT error message, install their
develop branch instead of the stable release).
To receive updates, install
[
GitHub Updater
](
https://github.com/afragen/github-updater
)
(temporarily, if you get a PCLZIP_ERR_BAD_FORMAT error message, be sure to use
their develop branch instead of the master release).
## Contributing
...
...
admin/dashboard.php
View file @
f68a9913
...
...
@@ -16,6 +16,11 @@ function w4os_dashboard_add_widgets() {
"OpenSimulator: "
.
__
(
'Grid status'
,
'w4os'
),
'w4os_dashboard_widget_gridstatus_handler'
);
wp_add_dashboard_widget
(
'w4os_dashboard_widget_newusers'
,
"OpenSimulator: "
.
__
(
'New users'
,
'w4os'
),
'w4os_dashboard_widget_newusers_handler'
);
}
function
w4os_dashboard_widget_gridstatus_handler
()
{
...
...
@@ -25,3 +30,6 @@ function w4os_dashboard_widget_gridstatus_handler() {
function
w4os_dashboard_widget_gridinfo_handler
()
{
print
(
w4os_gridinfo_shortcode
(
array
(
"title"
=>
""
)));
}
function
w4os_dashboard_widget_newusers_handler
()
{
print
(
w4os_newusers
());
}
includes/shortcodes.php
View file @
f68a9913
...
...
@@ -118,5 +118,33 @@ function w4os_shortcodes_init()
return
$content
.
$result
;
}
add_shortcode
(
'gridstatus'
,
'w4os_gridstatus_shortcode'
);
function
w4os_newusers_shortcode
(
$atts
=
[],
$content
=
null
)
{
return
w4os_newusers
();
}
add_shortcode
(
'w4os_newusers_shortcode'
,
'w4os_newusers'
);
}
add_action
(
'init'
,
'w4os_shortcodes_init'
);
function
w4os_newusers
()
{
if
(
!
W4OS_DB_CONNECTED
)
{
return
;
}
global
$wpdb
;
$recentusers
=
'<ul class="recently-user">'
;
$usernames
=
$wpdb
->
get_results
(
"SELECT user_nicename, user_url, user_email FROM
$wpdb->users
ORDER BY ID DESC LIMIT 5"
);
foreach
(
$usernames
as
$username
)
{
$user
=
$wpdb
->
get_row
(
$wpdb
->
prepare
(
"select * from "
.
$wpdb
->
prefix
.
"users where user_email = %s"
,
$username
->
user_email
));
$uuid
=
get_the_author_meta
(
'w4os_uuid'
,
$user
->
ID
);
if
(
$uuid
)
{
$recentusers
.
=
'<li>'
.
get_avatar
(
$username
->
user_email
,
32
)
.
" "
.
get_the_author_meta
(
'w4os_firstname'
,
$user
->
ID
)
.
" "
.
get_the_author_meta
(
'w4os_lastname'
,
$user
->
ID
)
.
"</a></li>"
;
}
else
if
(
!
$username
->
user_url
)
{
$recentusers
.
=
'<li>'
.
get_avatar
(
$username
->
user_email
,
32
)
.
" "
.
$username
->
user_nicename
.
" (
$uuid
)</a></li>"
;
}
else
{
$recentusers
.
=
'<li>'
.
get_avatar
(
$username
->
user_email
,
32
)
.
" "
.
'<a href="'
.
$username
->
user_url
.
'">'
.
$username
->
user_nicename
.
"</a></li>"
;
}
}
$recentusers
.
=
'</ul>'
;
return
$recentusers
;
}
readme.txt
View file @
f68a9913
...
...
@@ -36,30 +36,32 @@ section for upcoming functionalties.
### Roadmap
####
short term (for 1.0
release)
####
Short term (version 1.0, WordPress repository
release)
- Auth with avatar credential (as fallback to wp auth).
Create new WordPress user if auth by avatar
- option to use WordPress name as avatar name (in this case, lock WordPress
name changes once an avatar is set)
- Create avatar from standard wp-admin/profile.php page
- Check if avatar password is properly updated after a password reset request
- Auth with avatar credential (as fallback to wp auth)
* Create new WordPress user if auth by avatar
- integrate web asset server
- sidebar grid info and grid status widgets
####
m
iddle term
####
M
iddle term
- User profile
- Start / Stop regions
- Create region from admin
- Admin Start / Stop regions
- Admin Create region
- Admin Use sim/grid configuration file to fetch settings if on the same host
- Helpers (assets, search, currency, map...)
- Use sim/grid configuration file to fetch settings if on the same host
- *Use cache for grid info*
- Use cache for grid info
####
l
ong term
####
L
ong term
- Admin create users
- Admin create models (from current appearance)
- Choice between Robust console or database connection
- User
own regions control (Create / Start / Stop / B
ackup)
- User
's own regions control (create, start, stop, b
ackup)
- WooCommerce Subscriptions integration for user-owned Regions or other pay-for services
## Frequently Asked Questions
...
...
w4os.php
View file @
f68a9913
...
...
@@ -6,7 +6,7 @@
*
* Plugin Name: W4OS OpenSimulator Interface
* Description: WordPress interface for OpenSimulator.
* Version: 0.1
0.2
* Version: 0.1
1.0
* Author: Speculoos World
* Author URI: https://speculoos.world
* Plugin URI: https://git.magiiic.com/opensimulator/w4os
...
...