Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Help on finding a password?

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Howdy

I've got a little JavaScript form that I would like to figure out. Was hoping you guys could help me with that.

<script language="JavaScript">
<!--
x=prompt('Yay\n Enter password:',' ');
x=new String(x + " z");
var y = "1338";
var z = "1";
var f = "y - z";
if (x == f) {
location.href = "?page=soccer&pw=" + x;
}
else {
location.href = "blank.htm";
}
//-->
</script>

I can't seem to understand this. But I don't want access just to get passed it, I also want to learn how that works, so if you could explain a bit about how the code works, that would be great! Thanks

Btw, I'm Norwegian if there was any Norwegians here who finds it easier to write in our own language (if thats permitted)
 
Ranch Hand
Posts: 1970
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
A rather odd request, and certainly nothing to do with Java (which is a completely different language to JavaScript, despite similar names), so in the wrong forum. Should be in HTML/JavaScript. CarefullyChooseOneForum
 
Dibbe Dappert
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
I'm really sorry, I'm brand new here.
You had so many forums I didn't find anyone proper, so I decided to post it in the same forum I saw something similar.. But I'll post it again in the other forum, and you can close this topic, Administrators
 
Consider Paul's rocket mass heater.
    Bookmark Topic Watch Topic
  • New Topic