|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2007-11-12 18:59 UTC] johannes@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Nov 07 00:00:02 2025 UTC |
Description: ------------ When the name assigned to a form field contains such characters as '.' or space(' '), the $_GET/$_POST[$name] will not catch the contents of the field using that same name, instead you have to substite '.' or ' ' with '_' in the $_GET/$_POST function. Reproduce code: --------------- <?php $field = "text.field"; if(isset($_GET[$field])) { echo $_GET[$field]; } ?> <form method="get"> <label> <input type="text" name="text.field" id="text field" value="WORKS"/> </label> <p> <label> <input type="submit" name="button" id="button" value="Submit" /> </label> </p> </form> Expected result: ---------------- WORKS Actual result: -------------- nothing shows up, however changing $field = "text.field" to $field = "text_field" will display correct results.