?
Solved

SQL Font Color

Posted on 2009-07-15
2
Medium Priority
?
668 Views
Last Modified: 2013-12-13
I'm wanting to make the SQL result show in a lime green #00ff00 but i can't seem to make it work without causing an error.

The GiftPrice is what I would like #00ff00, along wiht the $ sign, which is showing green.
echo "<p><font color='#00ff00'>$</font>" .mysql_result($result,$i,"GiftPrice");

Open in new window

0
Comment
Question by:mimoser
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 39

Accepted Solution

by:
Roger Baklund earned 2000 total points
ID: 24866039
Try this:
echo '<p><font color="#00ff00">$'.mysql_result($result,$i,'GiftPrice').'</font>';
 
# ...or this:
$GiftPrice = mysql_result($result,$i,'GiftPrice');
echo '<p><font color="#00ff00">$'.$GiftPrice.'</font>';

Open in new window

0
 

Author Closing Comment

by:mimoser
ID: 31604084
Perfect, thank you!!
0

Featured Post

WordPress Tutorial 2: Terminology

An important part of learning any new piece of software is understanding the terminology it uses. Thankfully WordPress uses fairly simple names for everything that make it easy to start using the software.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Build an array called $myWeek which will hold the array elements Today, Yesterday and then builds up the rest of the week by the name of the day going back 1 week.   (CODE) (CODE) Then you just need to pass your date to the function. If i…
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Suggested Courses

765 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