Re: Need help with code (easy)
| From: | Joe Stump | Date: | Thu, 26 Oct 2000 01:39:59 +0000 |
| Subject: | Re: Need help with code (easy) | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-21996@lists.php.net to get a copy of this message | ||
I'm no professional at regexp's
if(!ereg("^[A-Za-z0-9]$",$username)){
echo "Spaces in $username!";
}
same for password
--Joe
On Wed, Oct 25, 2000 at 05:23:13PM -0700, Dallas Kropka wrote:
> I need a section of code that will verify a username and password.
>
> I only want it to contain A_Z a_z and 0_1 and underscore... No spaces symbles
>
> How do I do this?
================================================================================
= Joe Stump joestump98@yahoo.com http://www.miester.org =
================================================================================
"Real programmers don't comment their code.
It was hard to write, it should be hard to understand."