...

View Full Version : How to edit font color(red) ? please help :(



winpeace
01-30-2007, 05:42 PM
<?php
$topics = ssi_recentTopics(8, null, 'array');
foreach($topics AS $topic)
{
echo '<li>' . ''.$topic['link'] . '</li>' . '<br />';
}
?>

I call smf last post into joomla with this code.but ı want the font color red.when ı add
Kod:

echo '<li style="color:red">' . ''.$topic['link'] . '</li>' . '<br />'; this code only dot is red(.)but ı want font red

.like this

martialtiger
01-30-2007, 05:54 PM
You need to add ';' after red.

Good luck!

angst
01-30-2007, 05:55 PM
there must be more to it,
what exactly is $topic['link'] returning? is it just prue text, or is it return tags aswell?

winpeace
01-30-2007, 06:05 PM
You need to add ';' after red.

Good luck!

no it isn't work

CFMaBiSmAd
01-30-2007, 06:07 PM
Do you want the dot to be black and the text to be red?

If so, you would leave the <li> tag the way it was and you need to use a span around the text.

winpeace
01-30-2007, 06:16 PM
yes ı want dot black and text red.
can you help my english is poor
how can ı do your says?can you make this codes

CFMaBiSmAd
01-30-2007, 06:27 PM
I knew that was probably going to be the next question -

echo '<li><span style="color:red">' . $topic['link'] . '</span></li><br />';I took out all of the extra unneeded opening/closing quotes (easier to read.)

Edit: Sorry, left off a slash on the closing span tag...

winpeace
01-30-2007, 06:42 PM
ı found something

if
$topic['link'] it is white
but
if $topic['topic'] it is red

ı want link is red. :(

GJay
01-30-2007, 08:06 PM
does $topic['link'] contain an <a> tag?
you'll need to style that, either wherever it is given its value, or in a style elsewhere.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum