PDA

View Full Version : javascript changing input type in a form



malfist
March 27th, 2008, 03:12 AM
Question about javascript.

I have this login form, and screen space is lacking, so I'm not using labels. I have the the forms value set initially to what their function is, using javascript on the first click, it clears it. But the problem is the password box. Password boxs display only a specific echo character, so I think...no problem, change the type with javascript after the user clicks on it. So I do. I test it, it works in firefox, no errors. I test it in opera, it switches input type but doesn't clear until the second click. Odd, but not that important. Then I have a friend test it on IE, nothing. The text goes away but IE won't change the input type. Does anyone have a solution to this? A work around, or is my code just wrong.

Here's a link: http://soapbox.x10hosting.com

edit: horrible logo's will be replaced by a true artist, I designed them and I have no artistic talent (which is why the layout comes from an open source layout repo)

codeslicer
March 27th, 2008, 03:34 AM
Have a look here: www.thescripts.com/forum/thread705445.html

Hope this helps :)

malfist
March 27th, 2008, 03:58 AM
Seems to work, will be testing it on a VM shortly, will post back with info.

Thanks!

Update: Works!