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

Reply
 
Thread Tools
Details »»

Version: , by Parker Clack Parker Clack is offline
Developer Last Online: Nov 2013 Show Printable Version Email this Page

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

Well after attempting to do this before I found that it was making too much of a load on the server so I redid it.

After getting advice from Chen, bira and wluke I have finally gotten this done.

It allows a member to preview the first post in a thread, in your forumdisplay page, by putting their mouse pointer on the thread title. A separate box pops up with the first 500 characters of that post in it so you can preview the message before going into the rest of the thread.

This only works with IE and Opera. It works partially with Netscape (what else is new!).

Upload the attached .php file to your main forum directory and run it. Then read the included readme.txt file for instructions on the modifications needed to your files and templates.

(I have updated the file and put in a later post)

Parker

[high]The hack's zip file can be found in post #7 of this thread[/high]

Show Your Support

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

Comments
  #12  
Old 12-20-2001, 12:49 AM
bira's Avatar
bira bira is offline
 
Join Date: Nov 2001
Posts: 387
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

on a 40-threads page, the addition on my Bulletin Board was 10-15 kb.

The total page, with images and all, without the preview is 129kb; with the preview it's 144kb -- total of 15 kb more.

Using gzip compression (which I do), the difference is more significant and at the same time less so:

without the preview the page (without images) is 8106 bytes (8 kb). With the preview, the page is 14,323 bytes (14 kb).

Maybe because we use gzip compression, no one has so far complained about the page loading slower. But it is a point to think about if you are trying to cut down on bandwidth.

I might suggest, though, that those users who connect with modems should edit their own options to include less topics per page. If they are on a particularly slow connection, they ought to go for 10 topics per page.
Reply With Quote
  #13  
Old 12-20-2001, 02:20 AM
Parker Clack Parker Clack is offline
 
Join Date: Oct 2001
Posts: 351
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Lionel:

I didn't write that hack so you would have to ask the author about doing that. Good idea though.

Tommy Boy:

If you want to make this an option to use on your board click on the below .zip file and follow the instructions.

The default is set to off so if a member wants to use it they will have to turn it on.

Also, if you know how to change the tables around alter the preview add on to the thread table, that you just made, from 500 to 250 and change it from medium text to varchar(250) then change the 500 count in the .php files you just changed to 250.

Bira:

Look this new .zip over and if you see anything that needs changing let me know. Thanks.

Parker
Reply With Quote
  #14  
Old 12-20-2001, 05:09 AM
bira's Avatar
bira bira is offline
 
Join Date: Nov 2001
Posts: 387
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Parker I downloaded it and had a look. What is fundementally missing, is the code that is needed to be added to the user's Edit Options template

Likewise, you might want to expand it and add the same thing to user.php for the Admin CP user page.

Otherwise it looks good (though I've not tried it yet) :up:
Reply With Quote
  #15  
Old 12-20-2001, 08:29 AM
Parker Clack Parker Clack is offline
 
Join Date: Oct 2001
Posts: 351
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Doh!

I guess that would be necessary eh?

In your modifyoptions template you need to look for

$maxpostsoptions
</select></smallfont></td>
</tr>

and just below this add:

<tr>
<td bgcolor="yourcolorhere"><normalfont><b>Thread Preview Option On?</b></normalfont><br>
<smallfont>Selecting yes will allow you to preview the first post in a thread by putting your mouse pointer on the thread title.</smallfont></td>
<td bgcolor="yourcolorhere"><normalfont>
<input type="radio" name="threadpreview" value="yes" $threadpreviewchecked> yes
<input type="radio" name="threadpreview" value="no" $threadpreviewnotchecked> no
</normalfont></td>
</tr>

I will work on the Admin CP bit.

Thanks,
Parker
Reply With Quote
  #16  
Old 12-21-2001, 12:34 AM
Princeton's Avatar
Princeton Princeton is offline
 
Join Date: Nov 2001
Location: Vineland, NJ
Posts: 6,693
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great hack ... I love it. Thanks Parker. Bira, thank you for that update_preview. I was wondering why an existing link didn't show a preview waahoooo .
Reply With Quote
  #17  
Old 12-21-2001, 03:14 AM
Sadie Frost's Avatar
Sadie Frost Sadie Frost is offline
 
Join Date: Dec 2001
Location: Pittsburgh
Posts: 307
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This is so great!

One (stupid) question - should I now delete the threadpreview.php file?

Reply With Quote
  #18  
Old 12-21-2001, 03:47 AM
FWC's Avatar
FWC FWC is offline
 
Join Date: Oct 2001
Location: Ontario, CA
Posts: 821
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

[QUOTE]Originally posted by Sadie Frost
One (stupid) question - should I now delete the threadpreview.php file?

Reply With Quote
  #19  
Old 12-21-2001, 11:18 AM
Sadie Frost's Avatar
Sadie Frost Sadie Frost is offline
 
Join Date: Dec 2001
Location: Pittsburgh
Posts: 307
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you! Just didn't want to totally screw it up after I got it working lol
Reply With Quote
  #20  
Old 12-21-2001, 01:26 PM
Parker Clack Parker Clack is offline
 
Join Date: Oct 2001
Posts: 351
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Sadie:

Yeah, you can delete the previewthread.php and the previewthreadoptions.php files as they just make the mods to the database.

Thanks for the kudos guys and gals and I appreciate the fact that your members get something out of it. I know ours do.

Thank God there are people around here that know what they are doing though as the first version of this that I wrote was a real resource hog. This version works well on our board with over 22,000 registered and 6 million page views a month.

Parker
Reply With Quote
  #21  
Old 12-22-2001, 02:22 PM
freakyshiat freakyshiat is offline
 
Join Date: Nov 2001
Posts: 87
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

great work guys!!!

Now, could one of you outline the steps one more time just to be sure users dont screw things up?
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 09:02 AM.


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.04515 seconds
  • Memory Usage 2,304KB
  • Queries Executed 25 (?)
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
  • (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_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