> You should simply rely on the DOM API[1] and use:
>
> document.forms[0];
Depending on what you want to do with it, you may want to ensure it's
extended with the Prototype goodness:
$(document.forms[0]);
HTH,
--
T.J. Crowder
Independent Software Consultant
tj / crowder software / com
www.crowdersoftware.com
On Oct 21, 3:00 am, Tobie Langel <[email protected]> wrote:
> Little incentive in using CSS selectors, here, though you could get
> away with either:
>
> $$('form').first();
>
> or
>
> $$('form')[0]);
>
> You should simply rely on the DOM API[1] and use:
>
> document.forms[0];
>
> Best,
>
> Tobie
>
> [1]http://www.w3.org/TR/DOM-Level-2-HTML/html.html#ID-1689064
>
> On Oct 21, 12:24 am, patrick <[email protected]> wrote:
>
>
>
> > Is this the best way?
>
> > $$('body').first().down('form')
>
> > -patrick
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Prototype & script.aculo.us" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---