Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Beta Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Last / Next Thread Name in thread view Details »»
Last / Next Thread Name in thread view
Version: 1.00, by bad_madman bad_madman is offline
Developer Last Online: Oct 2023 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 06-26-2002 Last Update: Never Installs: 0
Is in Beta Stage  
No support by the author.

Showing in thread view the last thread name and next thread name instead of "last thread" and "next thread".

Advantage:
-I know before whether the thread is interesting for me.
-The link to the thread isn't shown, if there is not any next or last thread.
-Additional information possible (for example thread starter, views etc.).

Disadvantage:
- The previous thread isn't the previous thread any more, if somebody writes into this in the meantime :nervous:

See the screenshot for more informations.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #2  
Old 06-27-2002, 04:44 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hey mate, very good idea, so this links can be usefull
i don't think the old style is used so much
Reply With Quote
  #3  
Old 06-27-2002, 04:54 PM
bad_madman's Avatar
bad_madman bad_madman is offline
 
Join Date: Oct 2001
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ups. Have forgotten the code

Search in showthread.php for:

Code:
if ($goto=="nextnewest") {
  $thread = verifyid("thread",$threadid,1,1);
  if ($getnextnewest=$DB_site->query_first("SELECT threadid
            FROM thread
            WHERE forumid='$thread[forumid]'
              AND lastpost>'$thread[lastpost]'
              AND visible=1
              AND open<>10
            ORDER BY lastpost LIMIT 1")) {
    $threadid=$getnextnewest[threadid];
    unset ($thread);
  } else {
    eval("standarderror(\"".gettemplate("error_nonextnewest")."\");");
  }
}

if ($goto=="nextoldest") {
  $thread = verifyid("thread",$threadid,1,1);
	if ($getnextoldest=$DB_site->query_first("SELECT threadid
			FROM thread
			WHERE forumid='$thread[forumid]'
				AND lastpost<'$thread[lastpost]'
				AND visible=1
				AND open<>10
			ORDER BY lastpost DESC LIMIT 1")) {
		$threadid=$getnextoldest[threadid];
    unset ($thread);
	} else {
    eval("standarderror(\"".gettemplate("error_nonextoldest")."\");");
	}
}
and replace with:
Code:
if ($nextthread=$DB_site->query_first("SELECT threadid,title,views,replycount,postusername FROM thread WHERE forumid='$thread[forumid]' AND lastpost>'$thread[lastpost]' AND visible=1 AND open<>10 ORDER BY lastpost LIMIT 1")) {$nextthr=$nextthread[title]; if(strlen($nextthr)>45) $nextthr=substr($nextthr,0,42)."...";}
if ($lastthread=$DB_site->query_first("SELECT threadid,title,views,replycount,postusername FROM thread WHERE forumid='$thread[forumid]' AND lastpost<'$thread[lastpost]' AND visible=1 AND open<>10 ORDER BY lastpost DESC LIMIT 1")) {$lastthr=$lastthread[title]; if(strlen($lastthr)>45) $lastthr=substr($lastthr,0,42)."...";}
$nextlastthread="<table><tr>".iif($lastthr!="","<td align='right'><smallfont><a href='showthread.php?s=$session[sessionhash]&threadid=$lastthread[threadid]'><b>&laquo; Previous Thread</b><br>$lastthr<br>$lastthread[views] Views, $lastthread[replycount] Replys, Starter: $lastthread[postusername]</a></smallfont></td>","")."<td>&nbsp;</td>".iif($nextthr!="","<td><smallfont><a href='showthread.php?s=$session[sessionhash]&threadid=$nextthread[threadid]'><b>Next Thread &raquo;</b><br>$nextthr<br>$nextthread[views] Views, $nextthread[replycount] Replys,  Starter: $lastthread[postusername]</a></smallfont></td>","")."</tr></table>"
search in template showthread for:

Code:
<smallfont>
	<img src="https://vborg.vbsupport.ru/images/prev.gif" alt="" border="0">
	<a href="showthread.php?s=$session[sessionhash]&threadid=$threadid&goto=nextoldest">Last Thread</a>
	&nbsp;
	<a href="showthread.php?s=$session[sessionhash]&threadid=$threadid&goto=nextnewest">Next Thread</a>
	<img src="https://vborg.vbsupport.ru/images/next.gif" alt="" border="0">
	</smallfont>
and replace with:

Code:
$nextlastthread
Reply With Quote
  #4  
Old 06-27-2002, 05:04 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i was sure you want to post the code in the next post
A tip for the next version:
Don't make the Design hardcoded as you made here, would be better if you can set own designs in a template
Reply With Quote
  #5  
Old 06-27-2002, 05:20 PM
bad_madman's Avatar
bad_madman bad_madman is offline
 
Join Date: Oct 2001
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmm. Right. Thx for the tip. I always make this to my Hacks actually, too

Quote:
Originally posted by Xenon
i was sure you want to post the code in the next post
A tip for the next version:
Don't make the Design hardcoded as you made here, would be better if you can set own designs in a template
Reply With Quote
  #6  
Old 06-27-2002, 06:35 PM
Velocd's Avatar
Velocd Velocd is offline
 
Join Date: Mar 2002
Location: CA University
Posts: 1,696
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nice

I will probably only use the title of the thread though, that extra information seems to make it look cluttered.
Reply With Quote
  #7  
Old 07-02-2002, 03:51 PM
BigJohnson BigJohnson is offline
 
Join Date: Nov 2001
Posts: 535
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Can someone make it so it uses a template instead of being so hard coded because i have different styles and I have different pics for each style for the next and previous buttons. Thanks. That would really really help.
Reply With Quote
  #8  
Old 07-02-2002, 03:58 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i'm not the creator of it, and i think he'll do it more comfortable hisself, but you can do this:

replace
PHP Code:
$nextlastthread="<table><tr>".iif($lastthr!="","<td align='right'><smallfont><a href='showthread.php?s=$session[sessionhash]&threadid=$lastthread[threadid]'><b>? Previous Thread</b><br>$lastthr<br>$lastthread[views] Views, $lastthread[replycount] Replys, Starter: $lastthread[postusername]</a></smallfont></td>","")."<td> </td>".iif($nextthr!="","<td><smallfont><a href='showthread.php?s=$session[sessionhash]&threadid=$nextthread[threadid]'><b>Next Thread ?</b><br>$nextthr<br>$nextthread[views] Views, $nextthread[replycount] Replys,  Starter: $lastthread[postusername]</a></smallfont></td>","")."</tr></table>" 
with this:
PHP Code:
eval("\$nextlastthread = \"".gettemplate("nextlastthread")."\";"); 
then create the template nextlastthread and put in the infos you want , like $lastthread[postusername] or whatever
Reply With Quote
  #9  
Old 07-03-2002, 12:17 AM
bad_madman's Avatar
bad_madman bad_madman is offline
 
Join Date: Oct 2001
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thx Xenen
I will publish a new version with Templates - soon...
Reply With Quote
  #10  
Old 07-09-2003, 04:47 AM
padblaz padblaz is offline
 
Join Date: Apr 2003
Posts: 16
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i'm looking for this hack since a long time
do you think that you can publish the new version soon ?
up one year later
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


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


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05477 seconds
  • Memory Usage 2,303KB
  • Queries Executed 23 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (4)bbcode_code
  • (2)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete