define() - having problems to set CONSTANT value
Posted: Sat Feb 05, 2011 6:55 pm
Hi All,
I am having problems with the define() statement, in some cases it seems not to have any effect on the Constant I am trying to declare and the Constant keeps the value that was given to it in previous Functions.
If in a previous Function I declared:
define('DB_TABLE', 'old_table');
then running another Function in which I declare:
define('DB_TABLE', 'new_table');
echo DB_TABLE; // displays 'old_table' Previously defined in another Function not taking the new value...
Does anybody has any clues why this is happening ?
Thanks !
El Vasco
I am having problems with the define() statement, in some cases it seems not to have any effect on the Constant I am trying to declare and the Constant keeps the value that was given to it in previous Functions.
If in a previous Function I declared:
define('DB_TABLE', 'old_table');
then running another Function in which I declare:
define('DB_TABLE', 'new_table');
echo DB_TABLE; // displays 'old_table' Previously defined in another Function not taking the new value...
Does anybody has any clues why this is happening ?
Thanks !
El Vasco