immediate php help needed please?

Mitch

New member
lets start off by saying i'm decently versed in php, it's just... been a while since i've done any programming, and i can't remember what the hell i'm supposed to do to make this work.

lets say i have a page.... on this page, you have boxes to fill in, and a submit button.. you put in an order number lets say "123456"

Then you fill in information to each box for an item the person has ordered. quantity, part number, who we got it from, the date it was entered (which will be automatically entered from php).

order id [123456]


qty part# Vendor Date
[1] [abc12] [ven1] [2day]
[3] [ddd34] [ven1] [2day]
[1] [sss33] [ven3] [2day]
[2] [ffe343] [ven2] [2day]
[9] [abc12] [ven1] [2day]

[SUBMIT]


NOW... when i hit submit.....

EACH of these rows (items) needs to go to its OWN record.. not into 1 record..

in the database, each of those lines should be its OWN thing, and possess the same order number "123456"

So when you output the db to html it should look like this


order # qty part# Vendor Date
123456 [1] [abc12] [ven1] [2day]
123456 [3] [ddd34] [ven1] [2day]
123456 [1] [sss33] [ven3] [2day]
123456 [2] [ffe343] [ven2] [2day]
123456 [9] [abc12] [ven1] [2day]

-------

THAT PART IS EASY...... i have already done that...

what i need to know is how to do the loop, or whatever the hell i need to do to make it enter the info one line at a time


//submit

"while there is info in the box (i.e. keep going until you hit a blank box, or something);

open the database, write qty, part number, vender, date, shipped into that table...(new record)

is there more info?

yes?

ok.. go to the next line...

open the database, write qty, part number, vender, date, shipped into that table...(new record)

is there more info?

yes?

ok.. go to the next line...

open the database, write qty, part number, vender, date, shipped into that table... (new record)

more info?

no?

ok cool.. done....


does that make sense??????


WHILE doesn't do it....

FOREACH seems like it may, but i have no idea how..


HELP please i'm in a deadline for this.....

I have literally NO code for this part of it right now....
 
Back
Top