Discussion: $_POST array question
Afficher un message
Vieux 26/04/2008, 00h07   #3
Álvaro G. Vicario
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: $_POST array question

*** William Gill escribió/wrote (Fri, 25 Apr 2008 16:54:36 -0400):
> This may sound stupid but, in my testing I have noticed that I get every
> form field ($_POST array key), even if not populated. I am sure that's
> not how things worked before


More or less, that's how it's always worked. Browsers sends all form fields
except:

- Fields with "disabled" attribute
- Unchecked checkboxes

> but the point is, is it now safe to
> address $_POST array keys without testing to see if they exist (as long
> as I know the form field name exists)?


For God's sake, *never* trust external data!


--
-- http://alvaro.es - Álvaro G. Vicario - Burgos, Spain
-- Mi sitio sobre programación web: http://bits.demogracia.com
-- Mi web de humor en cubitos: http://www.demogracia.com
--
  Réponse avec citation
 
Page generated in 0,04709 seconds with 9 queries