I tried <input type="password" name="prompt"/> and it wont work.
I want the password I type in prompt will represent *.
TIA. :)
Printable View
I tried <input type="password" name="prompt"/> and it wont work.
I want the password I type in prompt will represent *.
TIA. :)
<input type="password" name="prompt"/>
What's the slash doing there?
Closing the Tag!
Instead of doing
<input></input>
you can just write <input/>
Thats valid!
I tried this and it works for me :
HTML Code:<HTML>
<HEAD>
<TITEL>Test</TITLE>
</HEAD>
<BODY>
<INPUT type="password" name="prompt" />
</BODY>
</HTML>
Thanks sgt for replying.
I think I didn't make it clear.
What I want is when I type in prompt(inputbox in vb) it will filter the character to *.
Code:HEAD>
<SCRIPT language="JavaScript">
<!--hide
var password;
<input type="password" name="prompt"??? />
password=prompt('Please enter your password to view this page!',' ');
if (password=="dead")
alert('Password Correct! Click OK to enter!');
else
{
alert('Your Dead');
}
//-->
</SCRIPT>
</HEAD>
Ah Ok now I understand what you want to do! Open a JS Prompt that is supposed to act like an Inbox with type set to password.
I am sorry, I dont know of a way to do this!
Why dont you just create a form where a user can enter Username and Password. Looks better imho.
Sorry for not being more of a help here!
Stephan
You cannot do that. Simple.
So what are the other way of prompting an input box to ask password?Quote:
Originally Posted by mendhak
Im sorry for stupidity, I'm very new at this thing. :(
It's not possible. End of discussion. Make a page that prompts for a password (not in a popup). Submit the page to the server. If it's correct, show the real page.
Well, that's not entirely correct. It is possible by making the server emit a 401 - Authorization Required response. The typical way to do this is the .htaccess file in Apache. This will make the browser pop up a box asking for username and password.
But it's not possible using JavaScript.
Thanks for the good advice CornedBee. I think I just make a page that ask password and not pop up.Quote:
Originally Posted by CornedBee