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,970
  • Latest: bynw
Stats
  • Total Posts: 196,058
  • Total Topics: 21,338
  • Online today: 234
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 1
  • Guests: 241
  • Total: 242
  • lurkalot

Recent Topics titles block in bold

Started by EasyRider, September 19, 2010, 04:36:54 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

EasyRider

ZarPrime,

Mate i try to change the Ichbin code prompt yesterday, but i don't know in what php file i must to do that.

I see your temporary  block  added in forum here. In your block usernames are bold.

I thing is easy; to change it for topic subjects only in bold..?  ???


SMF  1.1.11 / TinyPortal v1.0 beta 4 /default theme

ZarPrime

Well, since that topic is over 5 years old, the information that Bloc gave about what file to edit may not even be valid anymore.

I'll tell you what.  Let me look at the code and see if I can figure it out.  It might help to know what version of SMF and TinyPortal you are talking about doing this for.

ZarPrime

EasyRider

You right.. i see that is very old thread..

My specs:
SMF  1.1.11 / TinyPortal v1.0 beta 4 /default theme  

browser i use most opera and firefox

Thanks ZarPrime!
SMF  1.1.11 / TinyPortal v1.0 beta 4 /default theme

ZarPrime

EasyRider,

OK, try this code in a php block.  Change the 15 in the code to however many topics you want to show.


//Start Here ...
    // is it a number?
//if(!is_numeric($context['TPortal']['recentboxnum']))
// Change 15 in the next line to whatever number of recent posts you want to show
$context['TPortal']['recentboxnum']='15';

// leave out the recycle board, if any
if(isset($modSettings['recycle_board']))
$bb=array($modSettings['recycle_board']);
else
$bb=array();

$what=ssi_recentTopics($num_recent = $context['TPortal']['recentboxnum'], $bb, $output_method = 'array');
// Output the topics
$counter=1; $cmax=count($what);
echo '
<div style="width: 100%; overflow: auto; height: 30ex;">';
foreach($what as $w){
echo '
<div class="smalltext"><a href="'.$w['href'].'"><b>'.$w['short_subject'].'</b></a></div>
<div class="smalltext">', $txt[525], ' ', $w['poster']['link'], '</div>
<div class="smalltext">';
if(!$w['new'])
echo '<a href="'.$w['href'].'"><img border="0" src="'.$settings['images_url'].'/'.$context['user']['language'].'/new.gif" alt="new" /></a> ';

echo '['.$w['time'].']
</div>';

if($counter != $cmax)
echo '<hr />';
$counter++;
}
echo '
</div>';


This may not work with the latest TP if SMF 2.0 is installed (don't know, haven't tried it).  Does this do what you want?

ZarPrime

EasyRider

Great !!  O0

The only issue is the letters are too small and the horizontal rule in every title..

Thanks ZarPrime !!

SMF  1.1.11 / TinyPortal v1.0 beta 4 /default theme

EasyRider

I also change the  height: 30ex;  to 120ex  because was to small.
SMF  1.1.11 / TinyPortal v1.0 beta 4 /default theme

EasyRider

Now i use both down the old and up the new "recent topics" take a look the differences

http://www.adultforumgr.com/index.php
SMF  1.1.11 / TinyPortal v1.0 beta 4 /default theme

ZarPrime

Quote from: EasyRider on September 19, 2010, 07:59:48 PM
the horizontal rule in every title..


You mean the horizontal line between topics?  You can either remove this line ...


echo '<hr />';
         

or if you want a space in there between topics, you can replace that line with this ...


echo '<br />';
         

ZarPrime

EasyRider

Works perfect mate !   O0

Is posible to make letters biger..? like normal text ..?

If i change the
<div class="smalltext"> tags to something like "normaltext" you thing tha works..?

SMF  1.1.11 / TinyPortal v1.0 beta 4 /default theme

ZarPrime

Hmmm, you mean just for the titles, right?

OK, try changing this line ...


<div class="smalltext"><a href="'.$w['href'].'"><b>'.$w['short_subject'].'</b></a></div>


to this ...


<div class="strong"><a href="'.$w['href'].'"><b>'.$w['short_subject'].'</b></a></div>


Does that make them too big?

ZarPrime

This website is proudly hosted on Crocweb Cloud Website Hosting.