diff --git a/Changelog.md b/Changelog.md index 17019a0..944bca7 100644 --- a/Changelog.md +++ b/Changelog.md @@ -10,6 +10,7 @@ - Uploads show with an arrow next to them along with the size of the uploaded file - Added mathematical expression parsing between dollar signs. - Generated previews now have etags. This should speed up load times of subsequent requests significantly. + - Added an extra debug variable that displays the top level page name (i.e. the page that has been requested). It can be used like this: `{{{~}}}` # Changed - Enhanced the dev help page some more diff --git a/build/index.php b/build/index.php index 1d6d64a..3dc875b 100644 --- a/build/index.php +++ b/build/index.php @@ -4122,7 +4122,7 @@ register_module([ register_module([ "name" => "Parsedown", - "version" => "0.6", + "version" => "0.6.1", "author" => "Emanuil Rusev & Starbeamrainbowlabs", "description" => "An upgraded (now default!) parser based on Emanuil Rusev's Parsedown Extra PHP library (https://github.com/erusev/parsedown-extra), which is licensed MIT. Please be careful, as this module adds a some weight to your installation, and also *requires* write access to the disk on first load.", "id" => "parser-parsedown", @@ -4243,6 +4243,9 @@ class PeppermintParsedown extends ParsedownExtra } $variableValue .= "\n"; break; + case "~": + if(!empty($this->paramStack)) + $variableValue = $this->escapeText($env->page); // TODO: Add a option that displays a list of subpages here } if(isset($params[$variableKey])) diff --git a/module_index.json b/module_index.json index adea918..6154f19 100644 --- a/module_index.json +++ b/module_index.json @@ -190,11 +190,11 @@ }, { "name": "Parsedown", - "version": "0.6", + "version": "0.6.1", "author": "Emanuil Rusev & Starbeamrainbowlabs", "description": "An upgraded (now default!) parser based on Emanuil Rusev's Parsedown Extra PHP library (https:\/\/github.com\/erusev\/parsedown-extra), which is licensed MIT. Please be careful, as this module adds a some weight to your installation, and also *requires* write access to the disk on first load.", "id": "parser-parsedown", - "lastupdate": 1460104210, + "lastupdate": 1460105270, "optional": false } ] \ No newline at end of file diff --git a/modules/parser-parsedown.php b/modules/parser-parsedown.php index 33b5307..009e6bb 100644 --- a/modules/parser-parsedown.php +++ b/modules/parser-parsedown.php @@ -1,7 +1,7 @@ "Parsedown", - "version" => "0.6", + "version" => "0.6.1", "author" => "Emanuil Rusev & Starbeamrainbowlabs", "description" => "An upgraded (now default!) parser based on Emanuil Rusev's Parsedown Extra PHP library (https://github.com/erusev/parsedown-extra), which is licensed MIT. Please be careful, as this module adds a some weight to your installation, and also *requires* write access to the disk on first load.", "id" => "parser-parsedown", @@ -122,6 +122,9 @@ class PeppermintParsedown extends ParsedownExtra } $variableValue .= "\n"; break; + case "~": + if(!empty($this->paramStack)) + $variableValue = $this->escapeText($env->page); // TODO: Add a option that displays a list of subpages here } if(isset($params[$variableKey]))