Quote:
Originally Posted by Aric
I'm no expert, but that is wrong? You just assigned a value to $paid, which of course got rid of his PHP notices.
The PHP notices are displayed because $paid has no value set before the conditional.
|
Yep, $paid = false sets $paid to false.
The warning goes away because it's perfectly legal code, but it's also perfectly useless - it will always be true. To confirm, try this:
$paid = 1;
if ($paid = false) {
echo "oops, wrong answer";
}
__________________
For historical display only. This information is not current:
support@bettercgi.com ICQ 7208627
Strongbox - The next generation in site security
Throttlebox - The next generation in bandwidth control
Clonebox - Backup and disaster recovery on steroids