RE: [PHP] Great javascript function
| From: | Anthony Martin | Date: | Thu, 28 Dec 2000 19:58:16 +0000 |
| Subject: | RE: [PHP] Great javascript function | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-32136@lists.php.net to get a copy of this message | ||
Quick answer: Nothing, if it works.
Which browser supports it?
Anthony
-----Original Message-----
From: Ignacio Vazquez-Abrams [mailto:ignacio@openservices.net]
Sent: Thursday, December 28, 2000 11:40 AM
To: Anthony Martin
Cc: 'php-general@lists.php.net'
Subject: Re: [PHP] Great javascript function
On Thu, 28 Dec 2000, Anthony Martin wrote:
> Ever use associative arrays to name a form element?
>
> <INPUT type="submit" name="doThis[foo]" value="Do Foo">
>
> Ever try to use that name with javascript?
>
> alert ( document.myform.doThis['foo'].value ) ;
>
> It doesn't work. Or at least, I don't see how it would. The brackets are
>
Quick question: What's wrong with document.myform["dothis[foo]"].value?
--
Ignacio Vazquez-Abrams <ignacio@openservices.net>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
For additional commands, e-mail: php-general-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net