Kim Christensen wrote:
On 2/20/06, David Dorward <[EMAIL PROTECTED]> wrote:

Element ids may not contain square brackets in HTML documents.


Get your facts straight, David. Square brackets works fine in HTML

David has his facts straight, just because something works (for you)
doesn't make it correct (MARQUEE tag anyone?):

<quote from="http://www.w3.org/TR/html4/types.html#type-name";>
ID and NAME tokens must begin with a letter ([A-Za-z]) and may be followed
by any number of letters, digits ([0-9]), hyphens ("-"), underscores ("_"),
colons (":"), and periods (".").
</quote>

what I do usually is misuse the square brackets in the name - to get
the arrays in php - and use a different string for the id (one that is
technically) valid for use in javascript.

Kim do the escaped sqaure brackets work in all majors browsers as
far as you know?

documents as long as you escape the ID when you need to reference them
by JS.

--
Kim Christensen
[EMAIL PROTECTED]


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to