Password protection

if someone would look, Im just trying to put a “password” protection on a part of a site. I created a button, and attached that button with a script:

on (release) { if (_root.password.value eq tommygun) { getURL(“secure.html”); } }

I want when they input the correct password, that they will be directed to the site. (there is more, but I just need to figure this out). any help would be most appreciated…and if someone has a much better way to do this…please tell…:smiley:

This should solve your problem.

on(release){
if(textField.text == correctPass){
Show status.text = “Password confirmed”;
_root.gotoAndPlay(“beginSite”);
//or you can use this
getUrl(“secure.html”);
}else{
Show status.text = “Error, try again!”;
_root.gotoAndPlay(“startAgain”);
}
}
Hope this helps.

Kyle

Password Tutorial
:slight_smile: