incubator-jspwiki-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Volkar, John M." <JVol...@medrad.com>
Subject RE: accepting forms input in a wiki page
Date Fri, 06 Feb 2009 12:53:51 GMT
Bob,

Just implement it using the FormDebugHandler.  Show & tell is easiest.  

But short answer:  The output is displayed on the same page as the form,
usually (always?) before the form elements themselves.


Regards,
John Volkar

See http://www.jspwiki.org/wiki/FormDebugHandler


-----Original Message-----
From: Bob Paige [mailto:bobpaige@gmail.com] 
Sent: Thursday, February 05, 2009 11:52 AM
To: jspwiki-user@incubator.apache.org
Subject: Re: accepting forms input in a wiki page

Lou,

Thanks! This sounds like just what I want.

Question about how it operates: I assume the user navigates to the wiki
page and the form appears. The user then enters the data in the fields
and presses 'submit', which posts to the server and the plugin. How is
the output displayed? Is the same page redisplayed with the form, but
the output is appended to the bottom? Or is a new page generated?

I want a clear description for my manager to increase his understanding
of what I am proposing.

--
Bobman

On Thu, Feb 5, 2009 at 11:06 AM, <Louis.Masters@log-net.com> wrote:

> Bob:
>
> I have this functioning in our wiki and our account managers love it.

> It is a set of wiki forms that access our time tracking DB.  The form 
> is pretty simple:
>
> [{FormOpen form='wallydevtestingform'}]
>
> ! Developer Testing
> __Release:__ [{FormInput type='text' name='release'}] \\ __Cutoff:__ 
> [{FormInput type='text' name='cutoff'}] \\
>
> [{FormInput type='checkbox' name='showDetails' value='showDetails'
> checked='true'}]Show Details\\
> [{FormInput type='checkbox' name='useLinks' value='useLinks'}]Link 
> WIDs\\ [{FormInput type='checkbox' name='plainTables' 
> value='plainTables'}]Use Plain Tables\\
>
> [{FormInput type='submit' name='submit' value='Submit'}] [{FormOutput 
> form='wallydevtestingform'
> handler='com.lognet.wiki.plugin.WallyWIDDevTestingPlugin'}]
>
> [{FormClose}]
>
> You need to make a custom plugin to handle the form request ( 
> com.lognet.wiki.plugin.WallyWIDDevTestingPlugin).
>
> The plugin is a bit long for this email, but I can send it to you if 
> you like.  It basically gets the parms from the form, connects to the 
> DB, gets the data and sends it back to the front-end.  There is an 
> example of this (minus the DB interaction) at 
> http://www.jspwiki.org/wiki/ContributedFormHandlers
>
> It should take you less than an hour to implement.
>
> -Lou
>
>
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> LOG-NET, Inc.
> The Logistics Network Management System 
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 230 Half Mile Road
> Third Floor
> Red Bank, NJ 07701
> PH: 732-758-6800
> FAX: 732-747-7497
> http://www.LOG-NET.com
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> CONFIDENTIAL & PRIVILEGED
> Unless otherwise indicated or if obvious from the nature of the 
> content, the information contained herein is privileged and 
> confidential information/work product. The communication is intended 
> for the use of the individual or entity named above.  If the reader of

> this transmission is not the intended recipient, you are  hereby 
> notified that any dissemination, distribution or copying of this 
> communication is strictly prohibited.  If you have received this 
> communication in error, please notify the sender immediately by 
> telephone (732-758-6800) or by electronic mail 
> (postmaster@LOG-NET.com), and destroy any copies, electronic, paper or
otherwise, which you may have of this communication.  Thank you.
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
>
>
> Bob Paige <bobpaige@gmail.com>
> 02/05/2009 10:29 AM
> Please respond to
> jspwiki-user@incubator.apache.org
>
>
> To
> jspwiki-user@incubator.apache.org
> cc
>
> Subject
> accepting forms input in a wiki page
>
>
>
>
>
>
> Can someone point me to how I could implement the following (and how 
> reasonable it might be):
>
> I frequently get requests from our support people to look up something

> in our transaction database. It is a relatively simple query for me, 
> but I have to use a SQL client to get the information. They ask me to 
> do it because they either don't know how or don't have access to the 
> database and the tools.
>
> Is there some way I could build a wiki page with a couple data entry 
> fields that, when submitted, performs the required database query(s) 
> and outputs some formatted response? I don't need to update the page 
> content at all; I'm really just using it as a simple forms interface 
> to a database.
>
> The (typical) example I am looking at right now is like this:
>
> Inputs:
> * client ID
> * unit ID
>
> Outputs:
> * batch in which it was processed
> * date it was processed
> * status (success/fail/error message)
>
> There are more complicated examples, but this is a good start.
>
> Is this doable with existing plugins (excellent!) or do I just need to

> write a plugin (certainly doable; I've written several already).
>
> --
> Bobman
>
>

Mime
View raw message