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

Reply
 
Thread Tools
Details »»

Version: 1.00, by Admin (Coder) Admin is offline
Developer Last Online: Nov 2024 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 02-17-2002 Last Update: Never Installs: 23
 
No support by the author.

This is a rather old hack I did some time ago for someone, but never really released it as a full hack.

Very simple, this hack lets you change the template the first post is using (in either all forums or only one), so it can look differently.
Great for article and review forums.

Before installing the hack, create a new template named "postbit_first" from the current "postbit" template. After you're done, you can edit that template and it will control the first post in the threads.

Everything else you need is in the attached file, have fun!

Chen

Show Your Support

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

Comments
  #42  
Old 03-18-2002, 06:31 AM
mas404 mas404 is offline
 
Join Date: Nov 2001
Posts: 32
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

it is not working
same problem wich SirSteve had !!!

also i have expand/contract hack installed .. what i should do now?
Reply With Quote
  #43  
Old 03-18-2002, 07:30 AM
Tim Wheatley's Avatar
Tim Wheatley Tim Wheatley is offline
 
Join Date: Nov 2001
Location: England
Posts: 489
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

HOW is it not working? SOME details might help

For example, if it's showing no post, and just showing the reply/post bars above and below where the post should be then your postbit_first template needs to be expanded due to the expand/contract hack. So just redo the template. If that's not your problem, give us some info
Reply With Quote
  #44  
Old 05-01-2002, 07:33 PM
TECK's Avatar
TECK TECK is offline
 
Join Date: Nov 2001
Location: Canada
Posts: 4,182
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

great hack. thanks firefly. i needed exacly this.
Reply With Quote
  #45  
Old 06-04-2002, 02:47 AM
The Piper's Avatar
The Piper The Piper is offline
 
Join Date: Apr 2002
Location: Brazil
Posts: 63
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I was trying to do as SirSteve suggested, to remove the Author/Thread/New Thread/Post Reply bit in the beginning of the post, and to have it only after the first post. So, I thought I could modify showthread.php like this:

Original Code:
Code:
  eval("dooutput(\"".gettemplate("showthread")."\");");
Modified Code:
Code:
if ($counter==1 and $pagenumber==1 and ($thread['forumid']==6 or $thread['forumid']==7 or $thread['forumid']==8 or $thread['forumid']==4)) {
  eval("dooutput(\"".gettemplate("showthread_first")."\");");
} else {
  eval("dooutput(\"".gettemplate("showthread")."\");");
}
Then I created a template called showthread_first which did not have that table cell with such things as author, thread, etc.

Unfortunately, that didn't work. I'm a newbie in PHP, but that seemed to have been a good solution for what I was trying to achieve. I'd appreciate any input on this...

Thanks a lot!

Paulo
Reply With Quote
  #46  
Old 07-27-2002, 01:22 AM
hamoe hamoe is offline
 
Join Date: Jul 2002
Location: oregon
Posts: 10
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

For those who had a problem like this one:

Warning: Missing argument 2 for getpostbit() in /usr/www/users/gandalf/starwarsguide.com/forums/admin/functions.php on line 57


It is an easy fix. and maybe firefly can update his hack with this if he feels like it . He has you change the following:

function getpostbit($post) {

To the following:

function getpostbit($post,$templatename) {

How about instead of that, you change it to the following:

function getpostbit($post,$templatename='postbit') {

That makes it so that second argument is optional, and if its not used, it defaults its value to postbit. That means that if any other calls are made to getpostbit() expecting the unhacked version of the function, they will operate as expected
Reply With Quote
  #47  
Old 11-03-2002, 04:27 PM
P45.net's Avatar
P45.net P45.net is offline
 
Join Date: Nov 2001
Posts: 8
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Cool.... added this for a book review section on my architecture site...
Reply With Quote
  #48  
Old 09-02-2003, 07:21 PM
Ian Cunningham Ian Cunningham is offline
 
Join Date: Feb 2002
Posts: 221
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Is there any way to get this to work on 2.3.2?
Reply With Quote
  #49  
Old 04-05-2005, 05:08 AM
Hooper's Avatar
Hooper Hooper is offline
 
Join Date: Oct 2001
Location: St. Louis, Mo
Posts: 286
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Has anything like this been released for vB3?
Reply With Quote
  #50  
Old 04-05-2005, 05:30 AM
Hooper's Avatar
Hooper Hooper is offline
 
Join Date: Oct 2001
Location: St. Louis, Mo
Posts: 286
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Something else I thought might work would be to allow the first post to use the postbit vb3 while the rest use legacy postbit. This would be sufficiant. Anything like this?
Reply With Quote
  #51  
Old 04-11-2005, 07:57 PM
index index is offline
 
Join Date: Aug 2003
Location: M.E
Posts: 37
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi There,

also I liked this hack a lot and I want to know if there's a hack like this made for 3.0.7 ?

waiting a reply

Thanks a lot
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 06:35 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.05554 seconds
  • Memory Usage 2,295KB
  • Queries Executed 27 (?)
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
  • (2)bbcode_code
  • (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
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)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_postinfo_query
  • fetch_postinfo
  • 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