Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases

Reply
 
Thread Tools
Details »»

Version: , by Island Roots Island Roots is offline
Developer Last Online: Aug 2004 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 12-14-2001 Last Update: Never Installs: 5
 
No support by the author.

(The creator of the original hack is DR2000; I have since then modified it further)

Here's the hack in a handy dandy text file:

Hack:lastthreadlastposticon.txt

It is incredibly simple...you need only edit one file and one template! It can be done in a couple minutes!

###Features###

- Shows the thread name of the last active post on the front page
- Shows the lastpost.gif icon for the theme you're using, instead of either A, using a clear (invisible) image, or using the default lastpost.gif image for the lastpost icon
- If the subject is long enough to start stretching the field on the index page, it'll show a shrinked version (i.e. "I need help with version.....).

Note: This has only been tested on version 2.2.1!

To see it in action, just visit www.ConsoleBoards.com !

Show Your Support

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

Comments
  #22  
Old 12-20-2001, 11:51 AM
Lesane's Avatar
Lesane Lesane is offline
 
Join Date: Oct 2001
Location: The Netherlands
Posts: 1,149
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

[QUOTE]Originally posted by Lesane
hmm.. somehow the forum dont shows \ \ in the code.

Epic, change in the select code in index.php this:

PHP Code:
THEN '' 
to:

THEN \ ' \ '

(without spaces)
Reply With Quote
  #23  
Old 12-20-2001, 02:25 PM
epic's Avatar
epic epic is offline
 
Join Date: Oct 2001
Posts: 33
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I have a db error when use THEN \ ' \ '
no other hacks!
Reply With Quote
  #24  
Old 12-20-2001, 05:50 PM
Island Roots Island Roots is offline
 
Join Date: Dec 2001
Posts: 41
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

[QUOTE]Originally posted by epic
I have a db error when use THEN \ ' \ '
no other hacks!
Reply With Quote
  #25  
Old 12-21-2001, 02:55 AM
epic's Avatar
epic epic is offline
 
Join Date: Oct 2001
Posts: 33
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

My server is php 4.0.4pl1 and MySql3.22.32
My vbb is 2.2.1
When i use this line
PHP Code:
$forums=$DB_site->query('SELECT forum.*, CASE WHEN icon.iconpath IS NULL THEN \'\' ELSE icon.iconpath END as icon, thread.title as thtitle FROM forum left outer join thread on thread.forumid = forum.forumid and thread.lastpost >= (forum.lastpost-30) LEFT OUTER JOIN icon ON icon.iconid=thread.iconid WHERE displayorder<>0 AND active=1 ORDER BY parentid,displayorder'); 
generate a Database error,like this
PHP Code:
Database error in vBulletin 2.2.1:

Invalid SQLSELECT forum.*, CASE WHEN icon.iconpath IS NULL THEN '' ELSE icon.iconpath END as iconthread.title as thtitle FROM forum left outer join thread on thread.forumid forum.forumid and thread.lastpost >= (forum.lastpost-30LEFT OUTER JOIN icon ON icon.iconid=thread.iconid WHERE displayorder<>AND active=1 ORDER BY parentid,displayorder
mysql error
You have an error in your SQL syntax near 'icon.iconpath IS NULL THEN '' ELSE icon.iconpath END as icon, thread.title as th' at line 1 
When i use this line
PHP Code:
$forums=$DB_site->query('SELECT forum.*, CASE WHEN icon.iconpath IS NULL THEN '' ELSE icon.iconpath END as icon, thread.title as thtitle FROM forum left outer join thread on thread.forumid = forum.forumid and thread.lastpost >= (forum.lastpost-30) LEFT OUTER JOIN icon ON icon.iconid=thread.iconid WHERE displayorder<>0 AND active=1 ORDER BY parentid,displayorder'); 
generate a error,info is
Parse error: parse error in /home/vb/index.php on line 92
Who can help me?
Reply With Quote
  #26  
Old 12-21-2001, 02:26 PM
Island Roots Island Roots is offline
 
Join Date: Dec 2001
Posts: 41
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

<i>Make sure</i> you didn't overwrite any other code besides the one you were suppose to edit. If that doesn't work, then I can't help you. It has worked perfectly on all other boards.
Reply With Quote
  #27  
Old 12-22-2001, 04:21 PM
trilOByte's Avatar
trilOByte trilOByte is offline
 
Join Date: Nov 2001
Location: England
Posts: 325
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Getting the same parse error here too! Wierd!
Reply With Quote
  #28  
Old 12-22-2001, 04:37 PM
nuno's Avatar
nuno nuno is offline
 
Join Date: Oct 2001
Posts: 469
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

find (index.php):

//Forum info
$forums=$DB_site->query('SELECT * FROM forum WHERE displayorder<>0 AND active=1 ORDER BY parentid,displayorder');

replace it with:

//Forum info
$forums=$DB_site->query('SELECT forum.*, CASE WHEN icon.iconpath IS NULL THEN \'\' ELSE icon.iconpath END as icon, thread.title as thtitle FROM forum left outer join thread on thread.forumid = forum.forumid and thread.lastpost >= (forum.lastpost-30) LEFT OUTER JOIN icon ON icon.iconid=thread.iconid WHERE displayorder<>0 AND active=1 ORDER BY parentid,displayorder');
Reply With Quote
  #29  
Old 12-22-2001, 10:47 PM
trilOByte's Avatar
trilOByte trilOByte is offline
 
Join Date: Nov 2001
Location: England
Posts: 325
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks man, that worked a treat
Reply With Quote
Reply

Thread Tools

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 03:22 AM.


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.04461 seconds
  • Memory Usage 2,286KB
  • 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_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (9)post_thanks_box
  • (9)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (9)post_thanks_postbit_info
  • (8)postbit
  • (9)postbit_onlinestatus
  • (9)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
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete