Hidden Fields - How to Use

Issues related to forms.
Post Reply
User avatar
Starb7
 
 
Posts: 292
Joined: Tue Sep 05, 2006 12:35 pm
Location: Derbyshire

Hidden Fields - How to Use

Post by Starb7 »

Hi All

I would like to use the Hidden Fields option in Forms but can't find any documentation other than 'you can add hidden fields...' etc.

I would like to be able to add a Time and Date field that get spassed though when the form is submitted. What do I need to put in these fields to get the date and time, is there are code/value parameter for these, eg $time?

TIA

Paul
User avatar
BaconFries
 
 
Posts: 5619
Joined: Thu Aug 16, 2007 7:32 pm

Re: Hidden Fields - How to Use

Post by BaconFries »

Did you look at "Google" as it is awash with information on the use of hidden fields. A quick search of "Google" using
hidden field date and time returned the following that may or may not what you need...
https://stackoverflow.com/questions/391 ... den-fields
User avatar
Starb7
 
 
Posts: 292
Joined: Tue Sep 05, 2006 12:35 pm
Location: Derbyshire

Re: Hidden Fields - How to Use

Post by Starb7 »

Hi BaconFries

No, I looking in the WWB Help Pages and Forums. I didn't see anything specific and from past experience, using some other external source of info such as Google doesn't always apply to what WWB can and does do.

I'll check when you have suggested and can see in the page you have linked, it shows the Name and Value fields but what about the ID field? Is this needed and what can it be used for?

Thanks for your help.

Cheers

Paul
User avatar
Pablo
 
Posts: 22422
Joined: Sun Mar 28, 2004 12:00 pm
Location: Europe
Contact:

Re: Hidden Fields - How to Use

Post by Pablo »

'Hidden Fields' is a standard HTML feature, it is not specific to WWB.
WWB only makes is easier to add the names/values to your forms.

https://developer.mozilla.org/en-US/doc ... put/hidden
User avatar
Starb7
 
 
Posts: 292
Joined: Tue Sep 05, 2006 12:35 pm
Location: Derbyshire

Re: Hidden Fields - How to Use

Post by Starb7 »

Hi Pablo

Thanks, looking at BaconFries reply too and that will sort it for me.

I did ask BaconFries what the 'ID' field what for and was it needed?

I suppose I could also use the RichText format too and use the standard variables. Does WWb have any 'fixed' or named ones or are they just the name of the fields, ie a field called 'Make a Selction' would have an html value of $Make a Selection or would the spaces break that?

Cheers
Paul
User avatar
BaconFries
 
 
Posts: 5619
Joined: Thu Aug 16, 2007 7:32 pm

Re: Hidden Fields - How to Use

Post by BaconFries »

Although WWB is not an HTML Editor but an HTML Generator external code can still be used. The url I have shown includes an example that includes the "ID" in the field which is used in the javascript for the date and time. As Pablos reply it is not specific to the program so you may need to look at a custom solution to use for what you need.
User avatar
Starb7
 
 
Posts: 292
Joined: Tue Sep 05, 2006 12:35 pm
Location: Derbyshire

Re: Hidden Fields - How to Use

Post by Starb7 »

Thanks BaconFries. Not being a 'coder' (I have some limited knoweledge) I have tended to rely on WWB to do the work. I think I might put a suggestion on the Suggestions page to have a list of options in the hidden fields ;) Cheers, Paul
Post Reply