[PATCH] Valid syntax for array creation from form elements

From: Date: Mon, 26 Nov 2001 01:39:34 +0000
Subject: [PATCH] Valid syntax for array creation from form elements
Groups: php.dev 
Request: Send a blank email to php-dev+get-71609@lists.php.net to get a copy of this message
I'd like to patch PHP to allow for an XHTML-valid syntax for creating PHP arrays from HTML elements 'input' (groups of type="checkbox") and 'select' (multiple="multiple"). Square brackets are not allowed in XHTML identifiers, so the current syntax name="someName[]" or name="someName[someKey]" is not valid. Square brackets are also not allowed in ECMAScript identifiers (e.g. variable names) or directly in CSS selectors. I propose a simple, valid alternative syntax, perhaps something like name="someName__" or name="someName__someKey__". I'd like to get feedback on the likelihood of that conflicting with any established practices or conventions (I know it would work fine for me), or suggestions of a better syntax. I'd also like to get a little guidance on exactly how to proceed with submitting such a patch. As far as I can see this would only require modifications to php_variables.c, rfc1867.c, and type.c. When responding to this thread, please CC me because I am not subscribed to the list. Thanks, Jesse McCarthy

« previous php.dev (#71609) next »