Guest Posted June 25, 2003 Posted June 25, 2003 Originally posted in Tips and tricks forum ..... I'm trying to find a way to include a $variable within my product descriptions. I've tried every combination of quotes I know - but nothing seems to work. I'm now thinking of parsing each description, to look for something like <-- $variable --> and pull the variable out, then echo it ..... in a similar way that PHP Nuke picks up page breaks within articles. Has anyone found an easier way of including variables ? BrianD
Guest Posted June 25, 2003 Posted June 25, 2003 have you tried doing an eval on it before it gets displayed
Guest Posted June 25, 2003 Posted June 25, 2003 to elaborate on that a little .... replace <?php echo stripslashes($product_info['products_description']); ?> with something like <?php $product_description = $product_info['products_description']); eval ("$evaluated_product_description = "$product_description";"); echo stripslashes($evaluated_product_info); ?>
Recommended Posts
Archived
This topic is now archived and is closed to further replies.