Forums
This topic is locked
Passing those darn var's around
Posted 02 Dec 2002 06:03:56
1
has voted
02 Dec 2002 06:03:56 chris Criswell posted:
I've created a database of printer cartridges and printers. I created a couple record sets that select the cartridge type and another to select the printer type. This works great with a drop down list I've created in mx.
Naturally, after they pick HP cartridge type X I want to display a page with places to buy (this also is databased and tested)
I figure I have to pass the cartridge type X into the select statement somehow
select a,b,c
from table
where cartridge_type = varname
This is where I'm stuck.
If someone could point me to a tutorial that would be great
Any help would be appreciated.
Chris
Replies
Replied 02 Dec 2002 06:46:22
02 Dec 2002 06:46:22 Owen Eastwick replied:
You're pretty much there.
Eiether set the recordset up with a run-time value of Request("SelectBoxName"
Or you can store it in a variable and use that as the run-time value:
varCartType = Request("SelectBoxName"
Is that enough to get you going or do you need a bit more info?
Regards
Owen.
Multiple Parameter UD4 / Access 2000 Database Search Tutorial:
www.tdsf.co.uk/tdsfdemo
Eiether set the recordset up with a run-time value of Request("SelectBoxName"

Or you can store it in a variable and use that as the run-time value:
varCartType = Request("SelectBoxName"

Is that enough to get you going or do you need a bit more info?
Regards
Owen.
Multiple Parameter UD4 / Access 2000 Database Search Tutorial:
www.tdsf.co.uk/tdsfdemo
Replied 05 Dec 2002 15:03:06
05 Dec 2002 15:03:06 chris Criswell replied:
I'm close.
Should create another PHP page to display my results passing the ID of the item selected to the next page where I can plug that in to the where clause?
select rows
from tables
where id = ?varname
something like that?
Do I create a record set for the new page as well using the select statement?
Thanks for the help.
You're pretty much there.
Eiether set the recordset up with a run-time value of Request("SelectBoxName"
Or you can store it in a variable and use that as the run-time value:
varCartType = Request("SelectBoxName"
Is that enough to get you going or do you need a bit more info?
Regards
Owen.
Multiple Parameter UD4 / Access 2000 Database Search Tutorial:
www.tdsf.co.uk/tdsfdemo
Should create another PHP page to display my results passing the ID of the item selected to the next page where I can plug that in to the where clause?
select rows
from tables
where id = ?varname
something like that?
Do I create a record set for the new page as well using the select statement?
Thanks for the help.
You're pretty much there.
Eiether set the recordset up with a run-time value of Request("SelectBoxName"

Or you can store it in a variable and use that as the run-time value:
varCartType = Request("SelectBoxName"

Is that enough to get you going or do you need a bit more info?
Regards
Owen.
Multiple Parameter UD4 / Access 2000 Database Search Tutorial:
www.tdsf.co.uk/tdsfdemo
Replied 05 Dec 2002 16:54:24
05 Dec 2002 16:54:24 Owen Eastwick replied:
Ah, sorry I don't use PHP. but the principle is the same, so create an input page and then a results page where you create a recordset using the variable or ID generated by the input page in your WHERE clause.
If that's not enough to get you going try posting in the PHP section of the forum.
Regards
Owen.
Multiple Parameter UD4 / Access 2000 Database Search Tutorial:
www.tdsf.co.uk/tdsfdemo
If that's not enough to get you going try posting in the PHP section of the forum.
Regards
Owen.
Multiple Parameter UD4 / Access 2000 Database Search Tutorial:
www.tdsf.co.uk/tdsfdemo