DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:displayfile

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
plugin:displayfile [2021-01-25 05:07]
– created jeckel
plugin:displayfile [2021-11-21 16:00] (current)
jeckel
Line 6: Line 6:
 email      : jeckelmail@gmail.com  email      : jeckelmail@gmail.com 
 type       : syntax type       : syntax
-lastupdate : 2020-01-24+lastupdate : 2021-01-28
 compatible : Elenor of Tsort, Frusterick Manners, Greebo, Hogfather compatible : Elenor of Tsort, Frusterick Manners, Greebo, Hogfather
 depends    :  depends    : 
Line 13: Line 13:
 tags       : code, display, file, include, syntaxhighlight tags       : code, display, file, include, syntaxhighlight
  
-downloadurl: https://gitlab.com/JayJeckel/displayfile/repository/archive.zip?ref=master+downloadurl: https://gitlab.com/JayJeckel/displayfile/-/archive/master/displayfile-master.zip
 bugtracker : https://gitlab.com/JayJeckel/displayfile/issues bugtracker : https://gitlab.com/JayJeckel/displayfile/issues
 sourcerepo : https://gitlab.com/JayJeckel/displayfile/ sourcerepo : https://gitlab.com/JayJeckel/displayfile/
Line 23: Line 23:
 ===== Installation ===== ===== Installation =====
  
-Search and install the plugin using the [[plugin:extension|Extension Manager]] or install directly using the latest [[https://gitlab.com/JayJeckel/displayfile/repository/archive.zip?ref=master|download url]], otherwise refer to [[https://www.dokuwiki.org/plugins|Plugins]] on how to install plugins manually.+Search and install the plugin using the [[plugin:extension|Extension Manager]] or install directly using the latest [[https://gitlab.com/JayJeckel/displayfile/-/archive/master/displayfile-master.zip|download url]], otherwise refer to [[https://www.dokuwiki.org/plugins|Plugins]] on how to install plugins manually.
  
 ===== Usage ===== ===== Usage =====
  
-This plugin offers a single custom element, ''displayfile'', that takes two arguments, ''lang'' and ''target''. The element is self-closing and should not be used as an open/close pair.+The plugin offers a single block element that expands into the content of the specified file. The element is self-closing and should not be used as an open/close pair.
  
-^ Element | %%<displayfile%% ''lang'' ''target'' %%/>%% |+^ Element ^ Note ^ 
 +''%%<<display file LANG TARGET>>%%'' | | 
 +''%%<displayfile LANG TARGET />%%'' | DEPRECATED |
  
-|< 100% - - 100% >| 
 ^ Argument ^ Required ^ Description ^ ^ Argument ^ Required ^ Description ^
-| ''lang'' | yes | The language of the content file. This is used by Dokuwiki's built-in syntax highlighting GeSHi library. To disable syntax highlighting, specify a dask (-) character for the lang value. The supported lang values are the same as those provided by Dokuwiki's %%<code>%% and %%<file>%% markup and can be found on the Dokuwiki syntax page: [[https://www.dokuwiki.org/wiki:syntax#syntax_highlighting|Syntax Highlighting]] | +| ''LANG'' | yes | The language of the content file. This is used by Dokuwiki's built-in syntax highlighting GeSHi library. To disable syntax highlighting, specify a dask (-) character for the ''LANG'' value. The supported ''LANG'' values are the same as those provided by Dokuwiki's %%<code>%% and %%<file>%% markup and can be found on the Dokuwiki syntax page: [[https://www.dokuwiki.org/wiki:syntax#syntax_highlighting|Syntax Highlighting]] | 
-| ''target'' | yes | The specific part of a file path to the desired file on the local file system. This will be appended to the value of the plugin's ''root_path'' configuration option. The target value can be enclosed in single or double quotes (' or "). The target path part must be enclosed in quotes if it contains spaces. |+| ''TARGET'' | yes | The specific part of a file path to the desired file on the local file system. This will be appended to the value of the plugin's ''root_path'' configuration option. The ''TARGET'' value can be enclosed in single or double quotes (' or "). The ''TARGET'' path part must be enclosed in quotes if it contains spaces. |
  
 ===== Configuration Settings ===== ===== Configuration Settings =====
  
-The Display File Plugin has three settings that can be set in the Dokuwiki Configuration Manager:+The plugin provides several settings that can be modified through the [[https://www.dokuwiki.org/config:manager|Configuration Manager]].
  
-  - **Root Path** (''root_path'') - Specifies the root directory displayed file paths will evaluate relative to. The default value is an empty string, which effectively disables the plugin. +^ Setting ^ Default ^ Description ^ 
-  - **Deny Extensions List** (''deny_extensions''A space separated list of extensions that should disallowed by the ''displayfile'' element. The deny list supersedes the allow list. An empty list means no extension is explicitly disallowed. The default list includes ''sh''+''root_path'' | empty | Specifies the root directory displayed file paths will evaluate relative to. An empty value effectively disables the plugin. | 
-  - **Allow Extension List** (''allow_extensions''A space separated list of extensions that should allowed by the ''displayfile'' element. An empty list means any extension not in the deny list will be allowed. The default list includes ''txt'', ''php'', ''js'', and ''css''.+''deny_extensions'' | 'sh' | Space-separated list of extensions that should be disallowed by the ''displayfile'' element. The deny list supersedes the allow list. An empty list means no extension is explicitly disallowed. 
 +''allow_extensions'' 'txt php js css| Space-separated list of extensions that should be allowed by the ''displayfile'' element. An empty list means any extension not in the deny list will be allowed. |
  
 ===== Future Plans ===== ===== Future Plans =====
plugin/displayfile.1611547675.txt.gz · Last modified: 2021-01-25 05:07 by jeckel

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki