Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Passwords

Posted on 1998-09-10
2
Medium Priority
?
183 Views
Last Modified: 2010-04-09
I need a fast quick password java script to use in html. I am a new programmer to java and html, but my boss thinks I know it. Help
0
Comment
Question by:cgresham
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 

Accepted Solution

by:
mapper earned 200 total points
ID: 1837540
<html>
<head>
<title>Password Protected Page</title>
<h2>Page where you want to go&nbsp;<a href="http://www.therightpage.com"> IS HERE</a>
</head>

<body>

<script>
funci()
function funci() {
var dToday = new Date()
var nHours = dToday.getHours()
var nogo = ""
var yes = ""
if ((nHours >= 12))
while (yes != "cya") {
yes = prompt("Welcome.  Please Type The Correct Password For This Afternoon: "+Date(),"Type The Password Here .")
}
{alert("Welcome! ")
}

if ((nHours <= 12))
while (nogo != "cya") {
nogo = prompt("Type The Correct Password For This Morning: "+Date(),"Type The Correct Password Here. ")
}
alert("You Have Entered The Correct Password. ")
}
</script>



</body>
</html>
       
NOTE: this can be defeated easily - just disable your JavaScript and you will have access to the password...

Good luck
0
 

Author Comment

by:cgresham
ID: 1837541
This was quite an experience for me.  I need help and mapper answered me in a timely manor within about an hour.  This is a great resource! I hope that you folks continue this service, and when I become an "expert", I hope I can answer questions for you.

Thanks again!
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
When crafting your “Why Us” page, there are a plethora of pitfalls to avoid. Follow these five tips, and you’ll be well on your way to creating an effective page.
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

598 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question