The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Collapsable First Post using AJAX (or Last Post!) Details »» | |||||||||||||||||||||||||||
Collapsable First Post using AJAX (or Last Post!)
Developer Last Online: Feb 2012
[hr]-[/hr]
NOTICE: This is for vBulletin v3.6 ONLY. You can find a v3.5 compatible version here. [hr]-[/hr]*** Confirmed working on ALL vBulletin 3.6.x versions! *** [hr]-[/hr] Keywords: FORUMDISPLAY, search, results, collapse, AJAX, collapsable, first, last, unread, post Description: Allows you to expand/collapse the first, last or first unread post of a thread from FORUMDISPLAY and search results without the need to load the entire thread. Details: Upon perusing the wonderful deals over at slickdeals.net, I noticed this nifty feature which caught my eye. I found it quite useful as most people have a bad habit of not being very descriptive with their thread titles. This little trick made my browsing experience much more enjoyable, so naturally I had to borrow [read: shamelessly rip] the idea. Please note that no additional queries are added, unless using the 'First Unread Post' option. Otherwise, the only queries performed are the same as those when a thread is normally viewed. The magic behind this modification is performed by jQuery: The Write Less, Do More, JavaScript Library. [hr]-[/hr] Usage: Simply click the expand icon [+] in front of the thread title to expand, and the collapse icon [-] to collapse. Rocket science, eh? [hr]-[/hr] Installation:
Notes: All template modifications are made automatically. They attach to pretty common text locations, so modified styles shouldn't* be a problem. However, for those who wish (or need) to perform the edits manually, you can find that information here. [hr]-[/hr] Comments: As with all my hacks, this modification is provided free of charge. However, if you find this product useful and have money burning a hole in your pocket, feel free to make a small donation, I won't mind.. really. Version History:
[hr]-[/hr] Tips, Tricks and Modifications: Currently Known Bugs:
* Please note that this modification was developed on a forum with a userbase of 1 (myself). I've tested it for basic functionality but I cannot guarantee functionality or behavior on your forum. So, please -- make backups before installing this product! Show Your Support
|
Comments |
#2
|
||||
|
||||
wow man nice hack thanx for this i just love ajax
|
#3
|
|||
|
|||
will be installing this when i get home. awesome mod!
|
#4
|
|||
|
|||
<a href="http://www.4x4mecca.com/forum/forumdisplay.php?f=36" target="_blank">http://www.4x4mecca.com/forum/forumdisplay.php?f=36</a>
I get an error message when I try. The plus sign is there, but what I see is "There was an error. Please try again." |
#5
|
||||
|
||||
For those who have problems with the automatic template edits, or who just like to do things the hard way, here are the template edits required:
First, disable the automatic template edits:
Now perform the following template edits: In FORUMDISPLAY - FIND: HTML Code:
$headinclude HTML Code:
<script type="text/javascript" src="clientscript/jquery.js"></script> <script type="text/javascript" src="clientscript/vbulletin_vbpost.js"></script> [hr]-[/hr] In search_results - FIND: HTML Code:
$headinclude HTML Code:
<script type="text/javascript" src="clientscript/jquery.js"></script> <script type="text/javascript" src="clientscript/vbulletin_vbpost.js"></script> [hr]-[/hr] [CHANGED IN 1.2] In threadbit - FIND: (should be the first line) HTML Code:
<tr>
HTML Code:
<tr<if condition="empty($ajax_firstpost_excluded) || !in_array($forumid, $ajax_firstpost_excluded)"> <if condition="$vbulletin->options['ajax_firstpost_firstlast']">id="vbpostrow_$thread[lastpostid]"<else />id="vbpostrow_$thread[firstpostid]"</if></if>> FIND: HTML Code:
$thread[title_editable]
<div>
HTML Code:
<if condition="empty($ajax_firstpost_excluded) || !in_array($forumid, $ajax_firstpost_excluded)"><img id="vbpostimg_<if condition="$vbulletin->options['ajax_firstpost_firstlast']">$thread[lastpostid]<else />$thread[firstpostid]</if>" src="$stylevar[imgdir_button]/expand.gif" onclick="return vbpost_get(<if condition="$vbulletin->options['ajax_firstpost_firstlast']">$thread[lastpostid]<else />$thread[firstpostid]</if>)" onMouseOver="this.style.cursor='pointer';" /></if> |
#6
|
||||
|
||||
Quote:
Let me nose around a bit. |
#7
|
||||
|
||||
@4x4 Mecca:
Redownload the archive and upload/overwrite your existing vbpost_ajax.php with the new one. Let me know if that fixes it. |
#8
|
|||
|
|||
Thanks! I just edited the teplates manually just incase that was the problem. It still isn't working.
|
#9
|
|||
|
|||
Error is still there. Any idea what might be interfering?
|
#10
|
|||
|
|||
Quote:
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|