TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,973
  • Latest: NonStop
Stats
  • Total Posts: 196,231
  • Total Topics: 21,353
  • Online today: 651
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 0
  • Guests: 470
  • Total: 470

RSS for dummies

Started by Jeff, November 14, 2005, 03:56:01 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Jeff

Tried a new theme.  Still no dice...  I think I have something screwed up from the installation...


IchBin

What version of SMF/Theme/TP are you running?

Jeff

SMF 1.0.5
TP v.0.75

Note, I did have a problem with an RSS feed upon first configuring which required me to change a file manually per Bloc's instructions (search on my last posts or I'll find this afternoon).  Perhaps that did me in...

WebMasterZ

Yep thats exactly why it doesnt work now
Quote from: Bloc on November 11, 2005, 02:09:23 PM
you can open up TportalBlocks.tempalte and simply rename "function TPortal_rss()" to "function TPortal_none()". Then the rss block will not render and you can delete/adjust the block again in TPadmin.

Remember to rename back once you want rss blocks to work again.

http://www.tinyportal.net/smf/index.php?topic=1345.msg10836#msg10836

IchBin

Did you remember to name your function back like Bloc told you?
TPortal_none should say TPortal_rss in your TportalBlocks.tempalte file.

Jeff

I didn't change it back manually.  I thought the button selection would alter this file.  I'll change it in about an hour when I have SSH access to the server.

Thanks guys  8) 

Sorry for being  :uglystupid2:

Jeff

bingo... works like a champ.  Thanks much.

Jeff

Okay, now that I have that issue resolved, is there a way (well, of course there is, but how do I) to have RSS links spawn a new window when clicked?  I don't want people leaving my forum if they click an RSS link.

bloc

That would be something I need to add..the option of opening links in a new window.

You can do it already though..on a permanent basis..find this code in TPortal.php:
function endElement($parser, $tagName) {

  // This function is used when an end-tag is encountered.

  global $insideitem, $tag, $title, $description, $link, $tpimage;

  if ($tagName == "ITEM") {
   echo '<div style="font-size: larger; font-weight: bold;">';
   printf("<a href='%s'>%s</a>", trim($link),htmlspecialchars(trim($title)));

echo '</div><div class="smalltext" style="margin-bottom: 4px;">';
printf("%s",$description); // Print out the live journal entry
echo '</div>';
$title = $description = $link = $insideitem = false;
   }

}


add a target="_blank" to this line:

   printf("<a target="_blank" href='%s'>%s</a>", trim($link),htmlspecialchars(trim($title)));

This website is proudly hosted on Crocweb Cloud Website Hosting.