HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media


Welcome to TinyPortal. Please login or sign up.

December 03, 2023, 08:33:47 AM

Login with username, password and session length
  • Total Posts: 194,609
  • Total Topics: 21,189
  • Online today: 70
  • Online ever: 3,540
  • (September 03, 2022, 01:38:54 AM)
Users Online
Users: 0
Guests: 36
Total: 36

Forum news in a block

Started by YahMan, January 08, 2006, 05:20:52 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.


Is that possible? I don't like the SMF news function simply putting it at the top of the centerblocks. Depending on your theme off course. I was kinda hoping for an SSI function, but since the news function is SMF implemented, I guess that isn't possible. So, any ideas anyone?



If you go into TPAdmin, and then go to Edit Blocks, you will see a column called on/off/move.

scroll down to the Center Blocks section and you will see the green button, red button, 2 arrows and a little globe. The arrows and globe allow you to move a given block from one section to another.

Thus, clicking on the little arrow that points to the right will move it to the right side blocks. You would then have to set the value in the Pos column to determine where in right side blocks you want it located.


SMF news is not part of the TP blocks Rasyr. It is part of the theme for SMF. If you wanted to put it in a block you could always copy the code from the index.template.php file and put it in a block for TP. If you need help with this let me know and I will post the code for you.


Quote from: IchBinâââ,¬Å¾Ã,¢ on January 08, 2006, 05:48:10 PM
If you need help with this let me know and I will post the code for you.

That would be awesome, IchBin!



Hmm... Maybe I misunderstod.  ???

I thought he was referring to a standard news block. As in something that can be setup via the Edit Blocks screen. Oopsie... ;D

YahMan - are you referring to something within the blocks? Or the user/news bloc that all appear at the top together in the SMF (1.1 RC1 default/RC2 Babylon) theme?

If you want to get rid of that news block up there, in index.template.php, find the following code:

// Show a random news item? (or you could pick one from news_lines...)
if (!empty($settings['enable_news']))
echo '
<div class="headertitles" style="width: 260px;"><img src="', $settings['images_url'], '/blank.gif" height="12" alt="" /></div>
<div class="headerbodies" style="width: 260px; position: relative; background-image: url(', $settings['images_url'], '/box_bg.gif); margin-bottom: 8px;">
<img src="', $settings['images_url'], '/', $context['user']['language'], '/newsbox.gif" style="position: absolute; left: -1px; top: -16px;" alt="" />
<div style="height: 50px; overflow: auto; padding: 5px;" class="smalltext">', $context['random_news_line'], '</div>

And place a "/*" on the line before it and a "*/" on the line after it.

To set up the SMF news items in a block, just use a newsbox when you add a block (this pulls from the SMF news item list - at least that is what I think it is doing).


Ah yes, I forgot there is a news block. Thanks Rasyr!