Wrox Programmer Forums
|
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Flash (all versions) section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 21st, 2004, 04:51 PM
Friend of Wrox
 
Join Date: Sep 2003
Posts: 451
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to Ben Horne
Default A Little Problem

Hi all,

Well whaddya know? I've got a lot of Flash resources already to help me get started on my Flash website project soon. So far, I have found a lot of interesting stuff that I think I'm gonna be using on my Flash site:D.

Since I will be implementing password protection for my site, I need to have a system in place that lets visitors into the site ONLY if they have entered the correct password. I am using a book called Developing Websites with Macromedia Flash MX by Rickard Muller. . On page 290, step 7, it gives the following password protection code:


on (release) {
  password = password.toLowerCase();
  if (password == "flashmx") {
        gotoAndPlay ("Scene 2", 1);
 } else {
        gotoAndPlay ("Scene 3", 1);
 }
}


I want to modify the above code so that it is executed when the site visitor presses the Enter key. I also want to have 2 variations of a password so that it can be entered either way. Is there any way I can achieve this? The "password.toLowerCase" bit sets the password to lowercase. I don't want this to happen.



Thanks in advance,




Ben Horne
Madison Area Technical College - Truax
3550 Anderson Street
Madison, Wisconsin 53704-2599


-------------------------
http://community.webshots.com/user/valerian114

"There are two kinds of people in the world: Those who claim to be Flash junkies and those who actually are Flash junkies"
__________________
Ben Horne
-------------------------
I don\'t want to sound like I haven\'t made any mistakes. I\'m confident I have.

Most likely using FireFox and concocting my next Macromedia Flash project
Snibworks Forums Moderator

Welcome to the New Age









Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.