Re: Perhaps an incomplete $_POST

From: Date: Wed, 29 Aug 2007 19:41:30 +0000
Subject: Re: Perhaps an incomplete $_POST
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-261506@lists.php.net to get a copy of this message
On Wed, August 29, 2007 2:01 pm, Jay Blanchard wrote: > I just noticed something a little odd, and maybe there is a simple > solution. Given a form; > > <form name="foo" action="foo.php" method="POST"> > > The attributes, especially the name "foo", never appear in any > variables > array. I am thinking that this might be handy to have for several > reasons when processing the form. I have several reasons for needing > the > information, does anyone know how to get this in the processing script > without having to add hidden fields or do some Ajax magic? No. The FORM name attribute is simply not sent as part of the HTTP protocol. Maybe they shoulda thought of that in the beginning and done it, but doesn't happen and won't change soon. Add a hidden input or don't Design you application to know which form name it was. -- Please vote for this great band: http://acl.mp3.com/feature/soundandjury/?band=COMPANY-OF-THIEVES Requires email confirmation. One vote per day per email limit. Obvious ballot-stuffing will be revoked.

« previous php.general (#261506) next »