vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=235)
-   -   Miscellaneous Hacks - Sidebar Lastest Threads (https://vborg.vbsupport.ru/showthread.php?t=204659)

napy8gen 12-21-2009 01:20 AM

how to trim the long title text?

obetyance 03-06-2010 04:55 AM

Can we have a separate block per Board/Forum ID?

Ex:

Lastest Threads on FORUM ID 1, 2 & 3 (GEN COMMUNITY)

Lastest Threads on FORUM ID 5, 6 & 7 ( FOR SALE SECTION)

Lastest Threads on FORUM ID 8 & 9 (TECH SUPPORT)

Thanks! :)

edward hamilton 03-06-2010 08:04 PM

After having trouble with this mod I uninstalled it and used this code to get a list of recent posts. Nothing fancy but it works by making a plugin. If you don't know how to do it there are other threads about that.
I used cache_templates as the Hook Location. You can call it anything you want to.

PHP Code:

$numposts='5';


    
$thrdqry $vbulletin->db->query_read("
        SELECT forumid,threadid, title, dateline, lastpost, visible, open, lastposter      
        FROM " 
TABLE_PREFIX "thread
                WHERE forumid NOT IN (100,200,300)  AND visible = '1' 
        ORDER BY lastpost DESC
          LIMIT 0, 
$numposts ");

        while (
$thrds mysql_fetch_array($thrdqry))    
    {

    
$ttid $thrds[threadid]; 
        
$pstqry $vbulletin->db->query_read("
        SELECT postid      
        FROM " 
TABLE_PREFIX "post                        
                WHERE threadid= 
$ttid 
                ORDER BY postid DESC"
);

        
$psts mysql_fetch_array($pstqry);
 
        
$pstid $psts[postid];
            

$lastposted .=<<<EOD
<tr><td class="smallfont">

<b><a href="showthread.php?p=
$pstid#post$pstid">$thrds[title] </a></b></td><tr>
<tr><td>
$thrds[lastposter]<hr> </td></tr>
EOD;
            
    }
        
$db->free_result($thrds);
                
$db->free_result($psts); 

I put $lastposted in my Ultimate Side Column block after adding a heading called Recent Posts.

I hope this helps someone.

Silmarillion 03-12-2010 11:16 AM

How to delete/change the "Latest Threads" text?

MagicThemeParks 03-13-2010 01:03 PM

Quote:

Originally Posted by Silmarillion (Post 2002122)
How to delete/change the "Latest Threads" text?

Did a quick search and this may be your answer. https://vborg.vbsupport.ru/showpost....4&postcount=35

Silmarillion 06-10-2010 08:54 AM

What do i have to change to show the last poster in every thread?

Original-Code:

Code:

<tr>
    <td class="$class">
        <div class="smallfont"><a href="showthread.php?$session[sessionurl]t=$+++++++_slt[threadid]"><strong>$+++++++_slt[title]</strong></a></div>
<div class="smallfont">- von <a href="member.php?$session[sessionurl]u=$+++++++_slt[postuserid]">$+++++++_slt[postusername]</a></div>
    </td>
</tr>


Silmarillion 06-14-2010 01:13 PM

No one?

angeljs 10-24-2010 07:18 AM

Hi, is there any way to show attachments with this, instead of the title?

Sukubis 01-11-2011 11:56 PM

That works perfect, thank you =)

WebCraker 11-13-2011 03:17 AM

1 Attachment(s)
thnx alot man for this mod ..
Attached the mod translated into arabic
الموضوع والمنتج مترجم بتصرف باللغة العربية هنا


All times are GMT. The time now is 11:20 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01203 seconds
  • Memory Usage 1,748KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (1)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete