FormGuideSystem

Summary: Flexible, extensible, parameter-driven system to support the use of form pages
Version:
Prerequisites:
Status:
Maintainer: John Feezell
Categories: Forms Obsolete

<< Fox | Forms-related | Input >>

Goal

A flexible, extensible, parameter driven system to support the use of form pages within PmWiki.

(see CompareFormsRecipes)

Solution

To achieve this goal the FormGuideSystem (FGS) uses two php scripts.

  • One of the scripts is the main script that oversees and manages the interaction between the "user", the formguides, and PmWiki. This script is activated by using an include_once statement in the config.php file.
  • The other script contains specification for a form. This script is generated by the main script using parameters defined in a standard PmWiki page. The "instructions" in the PmWiki page are converted into a "formguide" by applying ?action=prepform to the PmWiki page.

Installation, Setup and Usage

Required Files
Attach:FGSv2Beta1.zipΔ

Basic First-Time Installation/Configuration (runs with PmWiki Beta28 ONLY!)

Note: FGS may be installed in either a local or farm setup. References that follow to the cookbook or wiki.d folders may be consider as either local or as a farm.

Download the above zip file and extract it to a working directory.

  • Place the FGS-v2-latest.php file in your cookbook directory.
  • For a local setup add the following to your local config.php script file.
include_once("/cookbook/FGS-v2-latest.php");
  • For a farm setup add the following to your farm config.php script file.
include_once("$FarmD/cookbook/FGS-v2-latest.php");
  • Copy the "Design-.." files to the appropriate wiki.d folder (this will cause a new group to become available to PmWiki called "Forms")
  • Copy the "Style-.." files to the appropriate wiki.d folder (these will also be related to the "Forms" group)
  • Create and edit a HomePage for the "Forms" group by entering .../Forms/HomePage?action=edit
    • on this new page enter
    (:pagelist group=Forms fmt=normal:)
    • then save the page.
  • Click on one of the "Design-.." links that should now be showing in the Forms.HomePage. This should display that "Design-.." page.
  • Now click on the "prepform" link on the page you selected.
FGS will attempt to create a directory called "formguides"
This directory needs to have the same permissions as wiki.d
You may need to manually create this directory and set the permissions
Once this directory is setup, try the "prepform" link again.

When FGS is working correctly, clicking the "prepform" link on one of the "Design-.." pages will cause FGS to prepare a formguide and then link to and open for editing the PmWiki page set by the attach instruction on that "Design-.." page.

At this point you can...

  • Define a form in a PmWiki page using FGS commands and format.
  • Define a styleguide in a PmWiki page using standard CSS formats.
  • Include one or more styleguides in a particular form.
  • Create the formguide file using ?action=prepform
  • Attach the formguide to a particular PmWiki page or group.

Usage
To activate a formguide with a particular wiki page simply include the following at the end of the URL address: ?action=edit&form=formguidename. For example, assuming that the FGS is installed

.../wiki/group/WikiPage?action=edit&form=FGS-SampleFormGuide

would open an existing or a new page with the associated form attached to group/WikiPage.

Demonstration Sites

Bundles and Styleguides View Open
Form Switching View Open
Including PmWiki Pages and Exporting Data View Open
Input Only Form View Open
Self replicating Dated Textarea View Open

History

  • FGSv2Beta1 was released on 31 March 2005

Planned Modifications

  • improve the export and formating of data from forms
  • review and strengthen the process for using the data from on form in another form or any PmWiki page
  • review and streamline the code
  • work on further integration with PmWiki
  • continue work on documentation
  • create some 'generic' forms and post here

Contributor

John Feezell, concept design and programming

See discussion at FormGuideSystem-Talk

Copyright

Copyright 2004-2005 John Feezell, All Rights Reserved. Copyright release is hereby given to PmWiki site administrators to include these scripts in support of normal site operations. Modifications that conform to current copyright law can be made to the scripts for personal use.

Merchantability

THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE