RE: [PHP] Variables
| From: | Maxim Maletsky | Date: | Wed, 11 Jul 2001 03:19:00 +0000 |
| Subject: | RE: [PHP] Variables | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-57299@lists.php.net to get a copy of this message | ||
if ($text1 == $text2) {
True;
}
else {
False;
}
THIS MUST WORK.
Sincerely,
Maxim Maletsky
Founder, Chief Developer
PHPBeginner.com (Where PHP Begins)
maxim@phpbeginner.com
www.phpbeginner.com
-----Original Message-----
From: James Bartlett [mailto:zotud@btinternet.com]
Sent: Wednesday, July 11, 2001 11:13 AM
To: php-general@lists.php.net
Subject: [PHP] Variables
Hi,
This might sound really simple but plz humour me :)
How can I tell if two text variables are equal to one another?
If I use..
if($text1 = $text2)
{
echo "The variables are equal";
}
else
{
echo "The variables are not equal";
}
then the code in the else state is always printed even if I know for a fact
that the variables are equal...
Any suggestions?
James