Re: [PHP] Setting focus on a textfield

2003-06-27 Thread Jason k Larson
This hardly belongs on the PHP list ... but try looking into JavaScript focus().

--
Jason k Larson
Angelo Zanetti wrote:

Hi guys how do I set the cursor to start in a particular textfield (password field) when my php page starts?

TIA



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


Re: [PHP] Setting focus on a textfield

2003-06-27 Thread Ernest E Vogelsinger
At 09:42 20.03.2003, Angelo Zanetti said:
[snip]

Hi guys how do I set the cursor to start in a particular textfield (password 
field) when my php page starts?

TIA
[snip] 

This is done with a JavaScript OnLoad handler:

body onload=forms[myform].elements[pass].focus();
...[page contents]...
form name=myform method=post ...
input type=password name=pass
/form
...[more page contents]...
/body


-- 
   O Ernest E. Vogelsinger
   (\)ICQ #13394035
^ http://www.vogelsinger.at/



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



Re: [PHP] Setting focus on a textfield

2003-06-27 Thread Marek Kilimajer
A little corection

Ernest E Vogelsinger wrote:
At 09:42 20.03.2003, Angelo Zanetti said:
[snip]
Hi guys how do I set the cursor to start in a particular textfield (password 
field) when my php page starts?

TIA
[snip] 

This is done with a JavaScript OnLoad handler:

body onload=forms[myform].elements[pass].focus();
body onload=forms['myform'].elements['pass'].focus();
...[page contents]...
form name=myform method=post ...
input type=password name=pass
/form
...[more page contents]...
/body



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


RE: [PHP] Setting focus on a textfield

2003-06-27 Thread Ford, Mike [LSS]
-Original Message-
From: Marek Kilimajer

A little corection

Ernest E Vogelsinger wrote:
 At 09:42 20.03.2003, Angelo Zanetti said:
 [snip]
 
Hi guys how do I set the cursor to start in a particular textfield
(password 
field) when my php page starts?

TIA
 
 [snip] 
 
 This is done with a JavaScript OnLoad handler:
 
 body onload=forms[myform].elements[pass].focus();
body onload=forms['myform'].elements['pass'].focus();

body onload=document.myform.pass.focus();

should also work -- as should

body onload=document['myform']['pass'].focus()

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