h4r00n Posted August 25, 2009 Share Posted August 25, 2009 Hi guys, quick question, I want what is searched for to appear orange, please find code below, it is currently bold but I just want it to have the following colour code - #FF7113: echo "You searched for <b>$search</b><hr size='1'>"; I also want the headings below the same colour //get data $Title = $runrows['Title']; $Location = $runrows['Location']; $Salary = $runrows['Salary']; $Sector = $runrows['Sector']; $JobType = $runrows['Job Type']; $Duration = $runrows['Duration']; $JobRef = $runrows['Job Ref']; $Description = $runrows['Description']; echo "<b>Title:</b> $Title<br> <b>Location:</b> $Location<br> <b>Salary:</b> $Salary<br> <b>Sector:</b> $Sector<br> <b>Job Type:</b> $JobType<br> <b>Duration:</b> $Duration<br> <b>Job Ref:</b> $JobRef<br> <b>Description:</b> $Description<p><br>"; Quote Link to comment https://forums.phpfreaks.com/topic/171866-how-can-i-change-the-colour/ Share on other sites More sharing options...
Alex Posted August 25, 2009 Share Posted August 25, 2009 This isn't a PHP question, it's html/css. <span style="color: #FF7113;">Colored Text</span> Quote Link to comment https://forums.phpfreaks.com/topic/171866-how-can-i-change-the-colour/#findComment-906229 Share on other sites More sharing options...
h4r00n Posted August 25, 2009 Author Share Posted August 25, 2009 Hi, sorry I forgot. Thanks for the code, but where in the coding to I insert that? Quote Link to comment https://forums.phpfreaks.com/topic/171866-how-can-i-change-the-colour/#findComment-906232 Share on other sites More sharing options...
citricsquid Posted August 25, 2009 Share Posted August 25, 2009 Place it around what you want to display a specific colour: <span style="color:#FF9900;">$variable</span> Quote Link to comment https://forums.phpfreaks.com/topic/171866-how-can-i-change-the-colour/#findComment-906234 Share on other sites More sharing options...
Zane Posted August 26, 2009 Share Posted August 26, 2009 or you can just make all bold tags have that color <br /> b {<br /> color: #FF7113;<br /> }<br /> Quote Link to comment https://forums.phpfreaks.com/topic/171866-how-can-i-change-the-colour/#findComment-906318 Share on other sites More sharing options...
Makeshift67 Posted August 27, 2009 Share Posted August 27, 2009 or, if you dont want all bold elements that color you can set a class for it.. <!-- HTML --> <b class="var">$variable</b> //CSS b.var { color: #FF7113; } Quote Link to comment https://forums.phpfreaks.com/topic/171866-how-can-i-change-the-colour/#findComment-907918 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.