[thelist] php variables in mysql output
Liz Lawson
lizlawson at charitycards.co.uk
Mon Dec 4 10:50:11 CST 2000
>Take a look at:
> http://www.php.net/manual/function.eval.php
>It should do what you desire.
>
yup, I thought there would be an official way of doing it...good old PHP.
>You really want to maximize your flexibility here - and be cautious to
>only use variables which will exist. Depending on your needs you might
>want to set the variables you expect to come out of the database to some
>default before printing them to the screen.
Good tip. (I set defaults for any variables in a script or template anyway:
they usually start out something like $colour = "Urgh! We didn't get a value
for the colour!" but they end up a lot prettier!)
thanks Joe
Liz
More information about the thelist
mailing list