[geeklog-devel] Geeklog Demo Mode

Wim Niemans niemans at nlbox.com
Thu Nov 12 12:03:22 EST 2015


For my plugin(s) I am using a sandbox mode.
If the constant is defined, than

— skip all sql updates and issue a message
— generate a test submit button in forms that redirects the form to a stub that lists GET, POST, FILES etc.

Just a thought. I am using this mainly for development.
Not to say that I have standard a debug area on the page, that, when activated, lists all debug of the script.

Cheers,
wim niemans




> Op 12 nov. 2015, om 16:14 heeft Tom <websitemaster at cogeco.net> het volgende geschreven:
> 
> If I have time I would like to add some sort of demo mode  to the next
> version of Geeklog.
> 
> I see a demo mode as a site used for testing and evaluating by the general
> public. It will be refreshed every X minutes by some other process by
> dropping and importing the database and either deleting and adding the files
> again or refreshing just certain directories. The Admin user of a demo site
> has its security rights reduced automatically.
> 
> Now I don't want this to be a huge endeavor but I would like it to include
> as many useful features as possible. Possible features include:
> 
> - Configuration. Hide completely and read only modes for Configuration Tabs
> and options
> - Allow read only modes for things like Plugin Admin, DB Backups, etc... (or
> at least disable certain features like plugin uploads, etc..)
> - Allow read only of Users and Groups OR somehow lock down or hide the key
> users and security features while still letting visitors create test users
> and groups
> - Develop this in mind so 3rd party plugins like the forum could take
> advantage of the demo mode.
> 
> 
> 1) My first thoughts is that you would enable the DEMO_MODE variable in the
> siteconfig.php and then add a bunch of if statements like below anywhere in
> the Geeklog core code we want to control what the demo mode has access to.
> 
> We could go a bit farther with this idea and add a demo mode array with
> different features set to true or false which would allow the admins to
> change things as needed. This could get a bit mucky in the configuration
> though.
> 
> if ( defined('DEMO_MODE') ) {
>    redirect_header($_CONF['site_url']."/index.php",10,'Uploads are disabled
> in demo mode');
>    exit;
> }
> 
> 2) My second idea would be in the install allow for the creation of a
> DemoAdmin account (along with updated articles, etc... to reflect demo mode)
> with the appropriate security features enabled which would use Geeklog's own
> security to control access. The Admin account for the site would still be
> the root user and private but the DemoAdmin account would be what is used by
> vistors to test things out. Doing this would mean we would need to add more
> security features to Geeklog to be able to control certain things like read
> only access to the plugin admin. The difficulties here would be the
> Configuration. We already have security for access to tabs or not. Allowing
> for viewing only for certain tabs and security options would be a lot more
> work and make the groups access list grow extremely long.
> 
> These are just only ideas and I may not have time to work on it right away
> but does anyone have any thoughts on the subject?
> 
> Tom
> 
> References:
> http://wiki.geeklog.net/index.php/Setting_up_a_Demo_Site
> http://project.geeklog.net/tracking/view.php?id=1059
> http://eight.pairlist.net/pipermail/geeklog-devel/2009-January/004000.html
> 
> 
> _______________________________________________
> geeklog-devel mailing list
> geeklog-devel at lists.geeklog.net
> https://pairlist8.pair.net/mailman/listinfo/geeklog-devel
> 




More information about the geeklog-devel mailing list