syntax for checking if string contains something

From: Date: Mon, 22 Oct 2001 19:05:10 +0000
Subject: syntax for checking if string contains something
Groups: php.general 
Request: Send a blank email to php-general+get-71862@lists.php.net to get a copy of this message
Hi, I was just going through my PHP book and I noticed that there was a way to check whether or not a form was filled out after pressing "submit". Things worked okay when I used the form checking method of just checking if a particular field was filled in. for example if ($email =="") checks if the $email variable was inputted by the user. However I was wondering how can I refine it so that it will also check if the $email variable contains an '@' sign? Thanks. Peter

« previous php.general (#71862) next »