Anadi Taylor wrote: > > Hi all, > > I have written a script that reads in information from a database: name, > email, password and username. > I am then searching through this information to match an email address > entered by a user ( this script is web based ) against the email address > pulled off the database. This all works fine except (ha ha - there is always > a BUT !!! ) when I find the email address I am looking for i want to jump to > the end of the 'while()' loop. I am sure this can be done but I just cant > figure it out !!! > > my code, without the jump is: > > while (@dbdata = $sth1->fetchrow_array()) > { > $dbname =$dbdata[0]; > $dbemail =$dbdata[1]; > $dbpwd =$dbdata[2]; > $dbusrname =$dbdata[3]; > > ## check to see if emails match > if ($usremail eq $dbemail) > { > $passcheck = "True"; > replyTo($usremail, $dbusrname, $dbpwd, $dbname); > ## jump to the end of loop last; # will do what you want :-)
perldoc -f last /Stefan > > } > } > > Also: the only reason I am having to pull all this data from the mySql > database is because for some very strange reason mySql doent like the '@' > and the '.' characters in a sql statement: I actually started with a SQL > query like: > > SELECT name, email, password, username FROM members WHERE > email='[EMAIL PROTECTED]'; > > BUT - it really doesnt like this, any ideas why ??? > > Thanks all for your valuable help and time > > Anadi > > You are just a dewdrop, and as you meditate the dewdrop starts slipping from > the petals of the Lotus towards the ocean. When the meditation is complete, > the dewdrop has disappeared into the ocean. Or you can say, the ocean has > disappeared into the dewdrop. > > Bhagwan Shree Rajneesh. > > _________________________________________________________________ > Express yourself with cool emoticons http://messenger.msn.co.uk > > -- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]