Are constants more efficient than variables that never change?

From: Date: Wed, 16 May 2001 01:25:26 +0000
Subject: Are constants more efficient than variables that never change?
Groups: php.general 
Request: Send a blank email to php-general+get-52968@lists.php.net to get a copy of this message
I may have a variable that changes page to page, but once it loads up, it never needs to be changed on that page. So my question is should i just do: define("myvar", 3); OR: $myvar = 3; does defining it make that much of a difference (if i have several of these variables that could be defined instead). - Noah

« previous php.general (#52968) next »