Reply to Re: Name of the Form that was POSTed?

Your name:

Reply:


Posted by Michael Fesser on 08/22/07 14:26

..oO(Tyler)

>Is it possible to determine the name of the form that caused a page to
>be submitted?

Forms don't have a name. Any 'name' or 'id' attributes applied to a form
can be used in client-side scripting, but are not submitted to the
server.

>The page that is POSTing to my script has two forms and I'd like to
>know if I can determine which one of them was submitted without having
>to add a hidden element to the forms.

IMHO using a hidden element is the most reliable and safest way.

Another way would be to give the submit buttons in each form different
names and check which button was pressed, but this might not always work
as expected.

Micha

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация