D&C GLug - Home Page

[ Date Index ] [ Thread Index ] [ <= Previous by date / thread ] [ Next by date / thread => ]

Re: [LUG] inputbox focus

 

On Fri, Jan 29, 2010 at 12:30 PM, kevin wrote:
> This is probbably the simplist method as you say (I was resorting to a
> function in javascript). BTW is id and name the same thing and /or can
> they have the same name? ie (or ff) can I have the tag name=plu and
> id=plu?

They are not the same thing, but some browsers (use to?) think so:

http://www.456bereastreet.com/archive/200802/beware_of_id_and_name_attribute_mixups_when_using_getelementbyid_in_internet_explorer/

In any case, using the same name is harmless and probably the safest
thing to do.

Martijn.

-- 
The Mailing List for the Devon & Cornwall LUG
http://mailman.dclug.org.uk/listinfo/list
FAQ: http://www.dcglug.org.uk/linux_adm/list-faq.html