Zone Edit Macro
Creates an editable zone into your page. |
Type | XAR |
Category | Macro |
Developed by | Lyes Bandou, Paul Pantiru |
Active Installs | 7 |
Rating | |
License | GNU Lesser General Public License 2.1 |
Table of contents
Description
The zone macro lets you insert an editable section, that stores the content into another document. The section displays a little pencil (both in view and inline mode) in the top right corner for the users that have edit rights, which if clicked redirects you to the inline mode of the document storing the content and lets you modify the title, content and a "Read more" link.
Usage
Insert the following macro on the page you want the editable section.
{{zone document="Space.Page" /}}
or
{{zone document="Space.Page" showTitle=true/}}
The document given as parameter must exist. You can add a ZoneCode.ZoneClass object and add some content in there. If the document does not have the object already, it will be added automatically and you will be able to edit after a refresh of the document from which you called the macro.
When editing a zone you have the posibility to edit:
- The title of the section
- The content of the section
- And the Read more link (Can be a wiki page or external link)
If you insert a link in the link section, a "Read more" button will appear.
If you decide to write the velocity code in the included document, then it's worth mentioning that the context will be that of the included document and not that of the document calling the macro.
This is how a section looks like in view mode, with no additional html or css attached, when not hovered:
And when hovered:
If you click the edit button (seen only when hovering the section), you will be redirected to the inline mode of the document storing the your content:
Prerequisites & Installation Instructions
We recommend using the Extension Manager to install this extension (Make sure that the text "Installable with the Extension Manager" is displayed at the top right location on this page to know if this extension can be installed with the Extension Manager). Note that installing Extensions when being offline is currently not supported and you'd need to use some complex manual method.
You can also use the following manual method, which is useful if this extension cannot be installed with the Extension Manager or if you're using an old version of XWiki that doesn't have the Extension Manager:
- Log in the wiki with a user having Administration rights
- Go to the Administration page and select the Import category
- Follow the on-screen instructions to upload the downloaded XAR
- Click on the uploaded XAR and follow the instructions
- You'll also need to install all dependent Extensions that are not already installed in your wiki
Release Notes
v1.4
v1.3
v1.2
v1.1
v1.0
Dependencies
Dependencies for this extension (org.xwiki.contrib.zoneedit:zoneedit-macro 1.4):
- org.xwiki.platform:xwiki-platform-rendering-wikimacro-api 5.4.4
- org.xwiki.platform:xwiki-platform-rendering-macro-velocity 5.4.4
- org.xwiki.rendering:xwiki-rendering-macro-html 5.4.4