diff --git a/modules/action-raw.php b/modules/action-raw.php index 35773cd..f9fae79 100644 --- a/modules/action-raw.php +++ b/modules/action-raw.php @@ -1,11 +1,13 @@ "Raw page source", - "version" => "0.4", + "version" => "0.5", "author" => "Starbeamrainbowlabs", "description" => "Adds a 'raw' action that shows you the raw source of a page.", "id" => "action-raw", "code" => function() { + global $settings; + add_action("raw", function() { global $env; @@ -15,6 +17,9 @@ register_module([ exit(file_get_contents("$env->storage_prefix$env->page.md")); exit(); }); + + add_help_section("800-raw-page-content", "Viewing Raw Page Content", "
Although you can use the edit page to view a page's source, you can also ask $settings->sitename to send you the raw page source and nothing else. This feature is intented for those who want to automate their interaction with $settings->sitename.
+To use this feature, navigate to the page for which you want to see the source, and then alter the action
parameter in the url's query string to be raw
. If the action
parameter doesn't exist, add it. Note that when used on an file's page this action will return the source of the description and not the file itself.
$settings->sitename supports the uploading of files, though it is up to " . $admindetails["name"] . ", $settings->sitename's administrator as to whether it is enabled or not (uploads are currently " . (($settings->upload_enabled) ? "enabled" : "disabled") . ").
+Currently Pepperminty Wiki (the software that $settings->sitename uses) only supports the uploading of images, although more file types should be supported in the future (open an issue on GitHub if you are interested in support for more file types).
+Uploading a file is actually quite simple. Click the "Upload" option in the "More..." menu to go to the upload page. The upload page will tell you what types of file $settings->sitename allows, and the maximum supported filesize for files that you upload (this is usually set by the web server that the wiki is running on).
+Use the file chooser to select the file that you want to upload, and then decide on a name for it. Note that the name that you choose should not include the file extension, as this will be determined automatically. Enter a description that will appear on the file's page, and then click upload.
"); } ]); diff --git a/modules/page-login.php b/modules/page-login.php index a2bd7a5..88129f8 100644 --- a/modules/page-login.php +++ b/modules/page-login.php @@ -6,6 +6,8 @@ register_module([ "description" => "Adds a pair of actions (login and checklogin) that allow users to login. You need this one if you want your users to be able to login.", "id" => "page-login", "code" => function() { + global $settings; + /* * _ _ * | | ___ __ _(_)_ __ @@ -86,6 +88,10 @@ register_module([ exit(); } }); + + // Register a section on logging in on the help page. + add_help_section("30-login", "Logging in", "In order to edit $settings->sitename and have your edit attributed to you, you need to be logged in. Depending on the settings, logging in may be a required step if you want to edit at all. Thankfully, loggging in is not hard. Simply click the "Login" link in the top left, type your username and password, and then click login.
+If you do not have an account yet and would like one, try contacting " . $settings->admindetails["name"] . ", $settings->sitename's administrator and ask them nicely to see if they can create you an account.
"); } ]);