Will anyone please help me create a LOGIN FUNCTION ON MY FLASH QUIZ. So that the user's name is displayed within the game. THIS IS OFFLINE by the way. Also the user is a able to create a username and password.
attached to the first keyframe that contains login_user, use:
var so:SharedObject = SharedObject.getLocal("login");
if(so.data.login){
login_user._visible=false;
// skip the login. user has already stored their user name
}
// if you have your user click a button to login after enter their name in login_use, use the following in that button's onRelease code:
so.data.login=login_use.text;
so.flush();
// whenever you want to use the login name from the scope of the sharedobject so, use:
so.data.login
// if you're outside that scope, you can always use:
var so:SharedObject=SharedObject.getLocal("login");
so.data.login
Like in most flash games where they key in their name and their data is saved in some sort of database. Because i want my application to have a function that when a user finishes a quiz, when he closes the flash and opens it again, the Subjects that he already took will have a mark indicating that he already finished it.
North America
Europe, Middle East and Africa
Asia Pacific