Setting a form input focus on HTML page - HELP HELP HELP

Discussion in 'JavaScript' started by RHIMLER14, Feb 1, 2009.

  1. #1
    Everything I search for on Google seems to make sense but where does the code like this go?

    $(':input:visible:enabled:first')
    
    HTML:
    said to load the first form input element on the page



    another


    onload="document.getElementsByTagName('input')[0].focus();"
    
    HTML:
    I know this goes in the <body> tag, but what other values do I need to change?



    Nothing seems to be working for me atleast can someone please give me some good in depth help? Thanks a bunch.
     
    RHIMLER14, Feb 1, 2009 IP