jerastraub Posted November 17, 2006 Share Posted November 17, 2006 Here is my code:[code]<span class="price">$ {$PrintPrice}</span>[/code]The problem I am having is how do I get the $ next to the price without it thinking that the additional $ is part of the variable. Like this:[code]<span class="price">$30</span>[/code] Quote Link to comment Share on other sites More sharing options...
taith Posted November 17, 2006 Share Posted November 17, 2006 [code]$variable = '<span class="price">$'.$PrintPrice.'</span>';[/code] Quote Link to comment Share on other sites More sharing options...
esukf Posted November 17, 2006 Share Posted November 17, 2006 [code]<?phpecho "<span class=\"price\">\${$PrintPrice}</span>";//orecho '<span class="price">$'.$PrintPrice.'</span>'; //<- preferred//or?><span class="price">$<?php echo $PrintPrice ?></span>[/code] Quote Link to comment Share on other sites More sharing options...
jerastraub Posted November 18, 2006 Author Share Posted November 18, 2006 Just wanted to say tks, for helping me out with this. I forget that i can just simply use \. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.