plugin:openas
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
plugin:openas [2022-02-14 18:29] – [openas Plugin] 24.78.8.122 | plugin:openas [2024-01-02 14:08] (current) – similar to bureaucracy plugin and move plugin Aleksandr | ||
---|---|---|---|
Line 7: | Line 7: | ||
type : syntax, | type : syntax, | ||
lastupdate : 2022-02-14 | lastupdate : 2022-02-14 | ||
- | compatible : anteater,rincewind,angua,adora belle,weatherwax,binky," | + | compatible : Anteater, Rincewind, Angua, Adora Belle, Weatherwax, Binky, Ponder Stibbons, Hrun, Ddetritus, Elenor |
depends | depends | ||
conflicts | conflicts | ||
- | similar | + | similar |
tags : pagemove, file, template, | tags : pagemove, file, template, | ||
Line 16: | Line 16: | ||
bugtracker : https:// | bugtracker : https:// | ||
sourcerepo : https:// | sourcerepo : https:// | ||
- | donationurl: | + | donationurl: |
---- | ---- | ||
- | |||
===== Installation ===== | ===== Installation ===== | ||
Line 33: | Line 32: | ||
There are three syntax formats: | There are three syntax formats: | ||
- | | + | |
- | ~~MoveTO> | + | ~~MoveTO> |
- | ~~OpenAS> | + | ~~OpenAS> |
+ | |||
+ | - '' | ||
+ | - '' | ||
+ | - '' | ||
+ | * this follows the format of the [[plugin: | ||
- | - '' | ||
- | - '' | ||
- | - '' | ||
- | * this follows the format of the [[plugin: | ||
- | |||
==== SaveAS ==== | ==== SaveAS ==== | ||
- | The SaveAS form will create a new page from the old page but leave the old page in tact. | + | The SaveAS form will create a new page from the old page but leave the old page intact. |
- | ==== MoveTO ==== | ||
+ | ==== MoveTO ==== | ||
- | The MoveTO form will create a new page from the old page and delete the old page. However, it will not delete the old page unless it is certain that the new page is in place, so that there is no danger of losing the old page. The MoveTo form performs a limited page move: it preserves backlinks and implements a number of other features, as described below in the [[# | + | The MoveTO form will create a new page from the old page and delete the old page. However, it will not delete the old page unless it is certain that the new page is in place, so that there is no danger of losing the old page. The MoveTo form performs a limited page move: it preserves backlinks and implements a number of other features, as described below in the [[# |
==== OpenAS ==== | ==== OpenAS ==== | ||
- | The OpenAS form requires the newpagetemplate plugin. | + | The OpenAS form requires the newpagetemplate plugin. This form will open the page '' |
- | ~~OpenAS> | + | |
This will open up the page : | This will open up the page : | ||
- | by '' | + | by '' |
- | There is an expanded syntax for this form of the plugin which gives it significantly greater flexiblity. See [[## | + | There is an expanded syntax for this form of the plugin which gives it significantly greater flexiblity. See [[# |
===== How it works ===== | ===== How it works ===== | ||
- | Once the page with the syntax markup is saved, it will now show a yellow box with a link. Clicking on this link will perform the desired action. | ||
+ | Once the page with the syntax markup is saved, it will now show a yellow box with a link. Clicking on this link will perform the desired action. In the case of pages which have been moved or saved-as, the new page will already be created, but links will not be updated until the new page is accessed from the link in the yellow box. In the case of a page which has been moved, the original page will remain on the server until you have linked to the new page, at which time the old page will be deleted. In the case of new page templates, the new page will open with the macro values filled in. The %%~~SaveAS> | ||
- | === Relative Links === | ||
- | Relative links will be re-written to the newly created file as absolute links. | ||
+ | === Relative Links === | ||
+ | Relative links will be re-written to the newly created file as absolute links. This is true of both the SaveAS and the MoveTO forms, | ||
===== Pagemove ===== | ===== Pagemove ===== | ||
- | In the MoveTo option, all backlinks to the page being moved are updated to the page id of the new page. | + | In the MoveTo option, all backlinks to the page being moved are updated to the page id of the new page. |
- | The plugin takes into consideration page locking. | + | The plugin takes into consideration page locking. So, if a page with backlinks is currently in use, it is not updated until the user with the lock exits the page. The original page remains in place until all of the pages with backlinks have been updated. Once all backlinks have been updated, the original page is removed. |
== Metadata and Indexing== | == Metadata and Indexing== | ||
- | This plugin does not update the Dokuwki | + | This plugin does not update the DokuWiki |
== Images == | == Images == | ||
- | The plugin in its present form does not update relative image links. | + | |
+ | The plugin in its present form does not update relative image links. If images are inserted using the media manager, this should not be an issue. For this situation try the [[plugin: | ||
== Backup == | == Backup == | ||
- | There is a backup system. A new meta directory is created: | + | There is a backup system. A new meta directory is created: '' |
===== Security ===== | ===== Security ===== | ||
- | There is basic built-in security for the **SaveAS** and **MoveTo** operations. | + | There is basic built-in security for the **SaveAS** and **MoveTo** operations. They check to make sure that the user has at least '' |
+ | |||
+ | Both **SaveAS** and **MoveTo** can be protected as well by standard acl rules which control who has access to the pages where the plugin code is embedded. Similarly the **OpenAs** operation can be protected by the site's [[:acl|]] rules. | ||
- | Both **SaveAS** and **MoveTo** can be protected as well by standard acl rules which control who has access to the pages where the plugin code is embedded. | ||
==== Spoofed URLs ==== | ==== Spoofed URLs ==== | ||
- | The plugin also intercepts any attempts to access the file system through spoofed urls. For these cases the url is redirected to another page. By default the redirection goes to an image in the plugin' | + | The plugin also intercepts any attempts to access the file system through spoofed urls. For these cases the url is redirected to another page. By default the redirection goes to an image in the plugin' |
- | images directory, which displays a 404 notice. | + | images directory, which displays a 404 notice. This can be changed in the Configuration manager either to a new image or page in the images directory or to an external url. If you use the images directory, your url should take this form: |
- | | + | |
===== Expanded Syntax for the OpenAs Format===== | ===== Expanded Syntax for the OpenAs Format===== | ||
- | With the expanded syntax, it is not necessary to pre-insert the '' | + | With the expanded syntax, it is not necessary to pre-insert the '' |
- | Different values can be entered for each access of the form. | + | |
+ | Different values can be entered for each access of the form. | ||
This is the expanded syntax. | This is the expanded syntax. | ||
< | < | ||
~~OpenAsVarsStart~~ | ~~OpenAsVarsStart~~ | ||
- | ~~OpenAsVAR> | + | ~~OpenAsVAR> |
- | ~~OpenAsVAR> | + | ~~OpenAsVAR> |
~~OpenAsNUM> | ~~OpenAsNUM> | ||
~~OpenAsVAR> | ~~OpenAsVAR> | ||
Line 122: | Line 125: | ||
~~OpenAsVarsClose~~ | ~~OpenAsVarsClose~~ | ||
~~OpenAS> | ~~OpenAS> | ||
+ | </ | ||
- | </ | ||
The '' | The '' | ||
Line 129: | Line 132: | ||
The '' | The '' | ||
- | :!: Important: '' | + | :!: Important: '' |
- | This above markup will create a Form with two text boxes and one textarea. | + | This above markup will create a Form with two text boxes and one textarea. '' |
Each instance of ~~OpenAsVAR> | Each instance of ~~OpenAsVAR> | ||
- | First Name: ~~OpenAsVAR> | ||
- | ** First Name: ** ~~OpenAsVAR> | ||
- | The Replacement variables are case-sensitive. | ||
- | You can use the '' | + | First Name: ~~OpenAsVAR> |
+ | ** First Name: ** ~~OpenAsVAR> | ||
+ | |||
+ | The Replacement variables are case-sensitive. There are two formatting features. The first will help to arrange the input elements on your page; this is the Dokuwiki line-break: '' | ||
+ | |||
+ | You can use the '' | ||
+ | |||
===== Example ===== | ===== Example ===== | ||
+ | |||
+ | |||
===== Markup ===== | ===== Markup ===== | ||
< | < | ||
~~OpenAsVarsStart~~ | ~~OpenAsVarsStart~~ | ||
- | ** Name: ** ~~OpenAsVAR> | + | ** Name: ** ~~OpenAsVAR> |
- | ** Age:** ~~OpenAsVAR> | + | ** Age:** ~~OpenAsVAR> |
** Address: ** ~~OpenAsVAR> | ** Address: ** ~~OpenAsVAR> | ||
** Address 2: ** ~~OpenAsVAR> | ** Address 2: ** ~~OpenAsVAR> | ||
Line 155: | Line 164: | ||
</ | </ | ||
- | This labels surrounded by asterisks (i.e. %%**%% Name: %%**%%) can be configured from the Configuration Settings as bold, italic, or underlined. | + | This labels surrounded by asterisks (i.e. %%**%% Name: %%**%%) can be configured from the Configuration Settings as bold, italic, or underlined. Default is '' |
===== Result ===== | ===== Result ===== | ||
- | {{ https:// | + | {{ https:// |
- | The Name, Age and Addr fields will be added to the HI and BYE fields. | + | The Name, Age and Addr fields will be added to the HI and BYE fields. The HI and BYE are constants, pre-set, the others are set by the user and will differ from page to page. |
==== Change Log ==== | ==== Change Log ==== | ||
+ | |||
{{rss> | {{rss> | ||
- | Complete listing of Changes: https:// | ||
- | ===== Discussion ===== | ||
- | For discussion, please use the dokuwiki [[http://forum.dokuwiki.org|forum]], | + | Complete listing of changes: https://github.com/ |
- | [[plugin: | + | |
+ | ===== Discussion ===== | ||
+ | For discussion, please use the DokuWiki [[https:// | ||
plugin/openas.txt · Last modified: 2024-01-02 14:08 by Aleksandr