|
From time to time developers request special features. These are not part of the regular Site or User Setups. These features are activated by adding a variable to the edit.cgi file right above the ############# line. Special Features are noted in Updates and the ChangeLog. Anyone can activate any of these Special Features on their installation by adding the variable to their edit.cgi.
$allow_autologin=1;
You can create a URL that will automatically login a user to edit. http://domain.com/editor/edit.cgi?getLogin=username|password will login to the toolbar. http://domain.com/editor/edit.cgi?getLogin=username|password|/page.html will login and load /page.html into the editor. This feature requires version 7.01.20090317 or greater. The variable $allow_autologin must be set in edit.cgi.
$demo=1;
If you add $demo=1; to edit.cgi the entire installation is converted to a demo installation. Users will not be able to save, saveas, upload etc; instead they will get a Disabled For Demo alert.
Suggested Use: Create a user named "demo" w/password "demo". Make the user a Type6, folder restricted and limited to editing in editblocks. Restrict the "demo" user to a folder named "demo" and put the page and a few images in that folder. Doctor the page with at least one editblock.
If you also want a working editor on the website, you will need to have two installations since the $demo=1; effects the entire installation. Suggest making a /demoeditor/edit.cgi installation in addition to the regular /editor/edit.cgi installation.
$email_source=1;
If you add $email_source=1; to edit.cgi an email will be sent to the Default Email (in Site Setup) containing the page's code before and after an edit is saved.
$copy_backup=1;
If you add $copy_backup=1; to edit.cgi the body innerHTML of the page will be copied to the operating systems clipboard before it is sent to the server. On most browsers this will activate a confirm to allow the browser access to the clipboard.
$backup_all=1;
If you add $backup_all=1; to edit.cgi a backup of the page's file will be made before it is overwritten with the new edits - even if the checkbox to do a backup is not checked in Save Edits Widget.
$log_saves=1;
If you add $log_saves=1; to edit.cgi an entry will be added to a file /txts/log.txt containing the username, path to the file, and the date whenever changes are saved. This is a self-cleaning file. $log_saves=1; will remove any entries older than 1 day (24 hour period), $log_saves=7; will remove any entries older than 7 days, $log_saves=30; will remove any entries older than 30 days, etc. The value of $log_saves determines the number of 24 hour days to save log entries.
|