Display Edit Form

Last modified by Thomas Mortagne on 2025/06/04 08:16

cogGeneric macro for displaying an edit form and do the processing of the postback of this form, which includes preparing document name from the user inserted title.
TypeXAR
Category
Developed by

Oana Florea, Anca Luca

Rating
0 Votes
LicenseGNU Lesser General Public License 2.1

Success

Installable with the Extension Manager

Description

The application includes a wiki page for the global macro and one for the translation keys available for the form buttons and errors.

createform.create=Create
createform.info.noinline=The form should only be used inline.

Available parameters for the createform macro:

Parameter NameDescription
itemspaceThe space where to create the new item.
itemtemplateThe template to create the item from.
itemparentThe parent of the item to create, will be the itemspace.WebHome if not specified.
labelThe label of the input generated by the create form macro for the new page title input. If this is missing, no label will be generated.

Example

Generate a form to create new blog post pages:

{{createform itemtemplate="Blog.BlogPostTemplate" itemspace="Blog" /}}

createnewpost.png

newblogpost.png

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:

  1. Log in the wiki with a user having Administration rights
  2. Go to the Administration page and select the Import category
  3. Follow the on-screen instructions to upload the downloaded XAR
  4. Click on the uploaded XAR and follow the instructions
  5. You'll also need to install all dependent Extensions that are not already installed in your wiki

Get Connected