By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,264 Members | 1,271 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,264 IT Pros & Developers. It's quick & easy.

HTML & PHP

P: n/a
how do i define a php variable using html?
i want to set an shtml page as a page with links to products - when each
button is pressed it it sets the product_category variable and lists all
entries with this variable - how do i set the html link to set the
variable?? wat do i need to set the product_category to?
Jul 17 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Hi Shaun

Use a link similar to <a href="script_file.php?product_category =x">Click
here</a>

In script_file.php you can get at this variable using either
$product_category or $_GET['product_category'] .

What you set product_category (the value of x in the link above) to is up to
you and your script! Does it need to be set to a valid value that is then
used to look up data in a database?

HTH
--
Paul Barfoot
"Shaun Rigby" <sh**********@hotmail.com> wrote in message
news:zH******************@fe2.news.blueyonder.co.u k...
how do i define a php variable using html?
i want to set an shtml page as a page with links to products - when each
button is pressed it it sets the product_category variable and lists all
entries with this variable - how do i set the html link to set the
variable?? wat do i need to set the product_category to?

Jul 17 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.