note 14212 rejected and deleted from language.types.array.php by zak

From: Date: Mon, 23 Jul 2001 00:35:09 +0000
Subject: note 14212 rejected and deleted from language.types.array.php by zak
Groups: php.notes 
Request: Send a blank email to php-notes+get-15684@lists.php.net to get a copy of this message
This is what I got when I turned full error reporting (8) on for the FastTemplates class (http://www.thewebmasters.net/php/FastTemplate.phtml) and is an example of how php 4 has changed its handling of indices. Warning: Use of undefined constant start - assumed 'start' Warning: Use of undefined constant theme - assumed 'theme' for the code start => "theme" . $HTTP_COOKIE_VARS[theme] . ".tpl" PHP 4 will give these warnings since if you don't use quotes around an index, it will assume the index is a constant, and is complaining that you have not defined it as such. The fix is to identify the index as a constant or a string and then treat it correctly. In these cases, both indices were strings and the fix was to add quotes. "start" => "theme" . $HTTP_COOKIE_VARS["theme"] . ".tpl" gemini1 at Gemini 1 Consulting LLC

« previous php.notes (#15684) next »