Reply
HTML forms - how would you accept an indeterminate number of inputs
Old 04-23-2007, 06:06 PM HTML forms - how would you accept an indeterminate number of inputs
damien_ls's Avatar
Layershift

Posts: 435
Name: Damien
Hi,

I'm currently creating a HTML form where I want to be able to accept an "unknown" number of inputs.

Basically I want to ask the user to enter multiple values for a particular data type, and the number of values could be between 1 and some arbitary number (e.g. 10).

In the database accepting this data, I will split submissions for this data into a separate table that is related to the main record - but what's the "best" way to accept this data via the form?

I don't really want to put a pre-determined number of input fields for it, and I want to find some way that will avoid splitting it into two steps (e.g. how many will you enter, next page, now you have x fields - as phpmyadmin does for example).

Ok - now reply with your suggestions/comments
damien_ls is offline
Reply With Quote
View Public Profile
 
When You Register, These Ads Go Away!
Old 04-24-2007, 05:46 PM Re: HTML forms - how would you accept an indeterminate number of inputs
chrishirst's Avatar
Super Moderator

Posts: 13,579
Location: Blackpool. UK
two ways;

1/ ask how many fields, submit that, then build the form server side and redisplay

2/ use javascript to add new child elements to the form
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
Indifference will be the downfall of mankind, but who cares?
Code Samples | People Counting System
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Reply     « Reply to HTML forms - how would you accept an indeterminate number of inputs
 

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.11441 seconds with 12 queries