Jump to content


Photo

text color of rss feed


  • Please log in to reply
4 replies to this topic

#1 grucker

grucker

    Member

  • Member
  • PipPipPip
  • 97 posts

Posted 12 February 2012 - 03:58 AM

I use various rss feeds on several websites. Similar code is used for all feeds in seperate functions.On one particular site all but one feed are correct the other shows title and date correctly but the description shows with yellow text.
<code>function render_products_from_BATLEYRUGBYSMALL() {
if ($xml = simplexml_load_file(STORE_XML_BATLEYRUGBYSMALL_FILE))
{ $output = "<div>";
// sets loop to 0
$i = 0;
// starts looping through products
foreach ($xml->channel->item as $item) {
$output .= '
<p><a href="'. $item->link.'"><span style="color:#990000; font-size:1.4em;"> '. $item->title.'</span></a></p>
<div style=" background-color:#993333;"> <p style="color:#fff!important;">'. $item->description.'</p></div>
<p class="black" >'. $item->pubDate.'</p>
';
// checks the loop. If it's >= 2 (indicating that it's looped 3 times)...
if ($i >= 0){
// start new row
$output .= "</tr>";
// reset loop
$i = 0;
}
// if not, add one to the loop
else
$i++;
break;
}
// finishes table
$output .= '</div>';
return $output;
}
else
$output .= 'News cannot be displayed at this time.';
}
</code>

As I said this same code works finne with other feeds. How do I get the text to show #ffffff.
Here is the site to see what I mean. I had to change the background color to get it to show.
http: // dewsbury.actinic9.co.uk
  • 0

#2 Eddie

Eddie

    Advanced Member

  • Advanced Member
  • PipPipPipPip
  • 3,625 posts
  • LocationTexas

Posted 12 February 2012 - 09:45 AM

Look at the css carefully:

<div style=" background-color:#993333;"> <p style="color:#fff!important;">'

You need a space between the color code and the exclaimation point.

<div style=" background-color:#993333;"> <p style="color:#fff !important;">'
  • 0

#3 grucker

grucker

    Member

  • Member
  • PipPipPip
  • 97 posts

Posted 12 February 2012 - 06:19 PM

Thanks for your interest, I added the space but it made no difference. The other feeds show correctly without the online code but not this one.
  • 0

#4 Guest_jini1

Guest_jini1
  • Guests

Posted 23 April 2012 - 04:17 AM

I looked through the style sheets but can't seem to find out how to change the color of the titles for the RSS feeds on my sidebar.

Edited by Andrea, 23 April 2012 - 05:28 AM.
Spam Link Deleted

  • 0

#5 Andrea

Andrea

    Advanced Member

  • Moderators
  • 5,722 posts
  • Facebook:https://www.facebook.com/aandbwebdesignAB
  • LocationSan Antonio, TX

Posted 23 April 2012 - 05:30 AM

I looked through the style sheets but can't seem to find out how to change the color of the titles for the RSS feeds on my sidebar.


And without seeing your site or at least the code, neither can we.

It might be best if you start a new thread with your issue, explain it a little better, give us somehting to work with, and DON'T POST UNRELATED SPAM LINKS.
  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users