Color qustion

Posted on 2011-04-29
Last Modified: 2013-12-12
How do I make the result appear in a different color other than #000, let's say blue.
echo "<td bgcolor='#FFFFFF' style='color: #000' align='center'> Borough: ".$result['county']."<br /></td>";

Open in new window

Question by:genesisvh
    LVL 6

    Expert Comment

    You simply change the color tag from #000 to something else.

    Heres a link to a color generator so you can see what color you want:

    Blue by the way is: #0000FF

    LVL 18

    Expert Comment

    by:Greg Alexander
    Have you tried:
    echo "<td bgcolor='#FFFFFF' style='color:blue' align='center'> Borough: ".$result['county']."<br /></td>";

    Open in new window


    Expert Comment

    Little bit confused as to what you mean, but you could use the following:
    echo "<td style="background-color: #ffffff;" align="center"><span style="color: #1c86ee;">Borough: ' . $result['county'] . '</span><br /></td>'; 

    Open in new window

    Try using span tags to wrap text in, and edit the CSS within the style attribute of the span.

    Author Comment

    No I think I didn't explain myself that well. #000 is for Borough but the result i would like to appear in blue. Sorry Thanks.
    LVL 18

    Accepted Solution

    echo "<td bgcolor='#FFFFFF' style='color: #000' align='center'> Borough: <span style='color:#00F'>".$result['county']."</span><br /></td>";

    Open in new window


    Author Closing Comment


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Highfive Gives IT Their Time Back

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Foreword (July, 2015) Since I first wrote this article, years ago, a great many more people have begun using the internet.  They are coming online from every part of the globe, learning, reading, shopping and spending money at an ever-increasing ra…
    Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
    The viewer will learn how to dynamically set the form action using jQuery.
    The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

    779 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    11 Experts available now in Live!

    Get 1:1 Help Now