Multiple forms in one PHP script

software development

#1

Hi! I’ve been looking all over the web, I see lots of people wanting to submit multiple forms to the same script, but not the issue I’m having, which is I have 2 forms on the same page that I want to submit to different places (the first goes to a search.php page, the second submits to PHP_SELF).

And it’s using an image for the submit button, though I’m not sure that matters. Basically this is a shopping cart with a search feature on every page. it works fine on pages without the second form. The search bar is in the header. On the item detail page (where you add the item to the cart), the search breaks.

Any ideas?

================================
Angela Gann
CrimsonDryad Web Design Services
Web Design, Custom Software Development
http://www.crimsondryad.com


#2

Make sure you are using valid markup, check that each form and input has a name, verify that the methods and actions are set correctly…

What happens to the search on an item detail page?

Check out Gordaen’s Knowledge, the blog, and the MR2 page.