Newbie dummy questions..... error messages

From: Date: Mon, 12 Feb 2001 14:08:39 +0000
Subject: Newbie dummy questions..... error messages
Groups: php.general 
Request: Send a blank email to php-general+get-39209@lists.php.net to get a copy of this message
I get the following on one of my pages, Warning: Use of undefined constant month - assumed 'month' in /usr/local/etc/httpd/vhosts/eastcoastbicycles.com/htdocs/index.php on line 121 Warning: Use of undefined constant mday - assumed 'mday' in /usr/local/etc/httpd/vhosts/eastcoastbicycles.com/htdocs/index.php on line 122 Warning: Use of undefined constant year - assumed 'year' in /usr/local/etc/httpd/vhosts/eastcoastbicycles.com/htdocs/index.php on line 123 and the offending lines are; $month = $today[month]; $mday = $today[mday]; $year = $today[year]; So I change them to; $month = $today['month']; $mday = $today['mday']; $year = $today['year']; and the problem goes away... simple enough I suppose but what baffles me is..... This site ran error free before, only after adding "Phorum" (anyone familiar with it?) do the original pages start to return these errors. Even more strange is they only return these error if one of the "phorum" pages is the referring page..... I was also getting a lot of stuff like 'undefined variable' when doing; if ($brand == 'nut') { $item = "Chris King 2nut Headset"; } So I changed it to; if (isset($brand)) { if ($brand == 'nut') { $item = "Chris King 2nut Headset"; } } and it's fine, but again, I'd only get the error if one of the "phorum" pages was the referring page..... Any thoughts/insight, anyone? BSDI BSD/OS 4.0.1 PHP Version 4.0B2 Zend Engine v0.90 -Brian ************

« previous php.general (#39209) next »