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: 1.00, by dabean dabean is offline
Developer Last Online: Dec 2003 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 01-08-2002 Last Update: Never Installs: 122
 
No support by the author.

This hack adds expansion and contraction support to the forum home page (index.php). The current version of this hack has been tested on vBulletin 2.3.2

Only supported browsers gain the ability to expand and collapse forum groups, non supported browsers do not gain anything, but no errors will be displayed.
Each users preference is saved to the database, additionally admins can select which forums are to be collapsed by default.

  • Browsers supported
  • Netscape6+/Mozilla0.6+
  • MS IE5+
  • Konqueror
  • Opera 7 support is included
  • Browsers unsupported
  • MS IE4 or earlier
  • Netscape 4 or earlier
  • Opera (version 6 and earlier)

Note: PHP 4.1.x or 4.2.x is required, PHP 4.0.x is now unsupported.

Instructions inside attachment.
Updated 4:18 PM 1/12/2002
- Packaged Post, Thread template Addon

Updated 7:53 PM 1/11/2002
- corrected installer

Updated 4:23 PM 1/11/2002
- Added DB support
- Added Per forum Collapsed Pref to admin cp

Updated 01/10/02 01:39am.
- Fixed missing line.

Updated 04/06/02 01:30am.
- Version 1.2
- PHP 4.1.x, 4.2.x support with or without register globals off.
- Performance tweeked javascript

Updated 06/06/02 11:20pm.
- Corrected templatecache bug

Updated 06/25/02
- Corrected formatting errors in readme

Updated 09/01/02
- vB 2.2.7 compatiblity statement, updated readme.

Updated 30/08/03
- vB 2.2.x and 2.3.x compatiblity statement, added new automatic testing script.

FAQ
Q: what exactly is Template_Option.txt?
A: Basically that exention was provided as a request to cover sites with the template modification that adds a "header" to each grouping.

Q: How do I show a forum depth greater than 2?
A: Open vB Admin cp set forum depth to your required level. Then create the additional templates. For template examples see https://vborg.vbsupport.ru/showthrea...465#post250465

Q: Can sub-forums be collapsed?
A: Yes. See the above answer for example templates.

Q: XYZ doesn't work help.
A: Check that all the template changes required have been made, 99% of problems are due to incorrect template alteration. Also use the cx_test.php to automatically check your installation!

Show Your Support

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

Comments
  #112  
Old 01-18-2002, 02:10 PM
dabean dabean is offline
 
Join Date: Oct 2001
Posts: 247
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Sven

I installed it yesterday and it works perfect with 2.2.1!

Just a little annoying though that settings are not saved for users - that's why I asked for the enhancement on the previous page.

Dabean, any comment on this?
They should be saved if the hack is installed correctly..
have you uploaded updateindex.php to your forums directory?

When i visited your site I received a 404 page not found when requesting that file, suggesting it has not been uploaded.

Shenlong: The name that you give the provided style set is not important what is important is that when you view your site via the the provided style the collapse/expand buttons should appear.
Reply With Quote
  #113  
Old 01-18-2002, 02:56 PM
Sven Sven is offline
 
Join Date: Oct 2001
Location: Neuss, Germany
Posts: 59
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I feel like a little dumbass...
I uploaded it to the admin dir....

Now it's working, thx a lot
Reply With Quote
  #114  
Old 01-20-2002, 06:31 PM
Arsenik Arsenik is offline
 
Join Date: Dec 2001
Posts: 26
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I installed the hack and works the way it was written for. Great job!

It would be very usefull if users could edit their user settings so that the forums status are remembered:

1- select if all the forums should be collapsed or expanded
2- select the categories they want collapsed or expanded
3- choose to use the default settings defined by the admin or not...

Since only the settings defined by the Admin for the default collapse/expand status of categories are remembered it would be nice if the users could edit their settings that way changes are remembered. Since changes arent remembered on the fly it would be a good way around the problem it seems.
Reply With Quote
  #115  
Old 01-20-2002, 11:27 PM
dabean dabean is offline
 
Join Date: Oct 2001
Posts: 247
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Arsenik
I installed the hack and works the way it was written for. Great job!

It would be very usefull if users could edit their user settings so that the forums status are remembered:

1- select if all the forums should be collapsed or expanded
2- select the categories they want collapsed or expanded
3- choose to use the default settings defined by the admin or not...

Since only the settings defined by the Admin for the default collapse/expand status of categories are remembered it would be nice if the users could edit their settings that way changes are remembered. Since changes arent remembered on the fly it would be a good way around the problem it seems.
Item 1., I'll consider it for a future version.
Item 2. how is this different to the current behaviour?
Item 3. ditto.

Both item 2 and 3 should be satisfied by hack as it exists currently when correctly installed.

Common installation errors are:
- updateindex.php not being uploaded to the forum directory.
- old version of the forumhome_expandjscript template.. not 100% sure why people are still having problems with this as the current zip contains a working version of the template.
Reply With Quote
  #116  
Old 01-21-2002, 02:22 AM
Arsenik Arsenik is offline
 
Join Date: Dec 2001
Posts: 26
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I was talking about the Users them selves and not only the Admin of the board.

I mean have the members edit their options and be able to use the settings the Admin selected by default or just not to use it at all if they dont want to. And also have the members be able to select what category they want collapsed or expanded like the Admin but in their own user options and be keept in the db since Collapsing and Expanding the forums on the fly doesnt work well. (the changes arent remembered)

Right now the hack keeps in the db the settings the Admin selects but not what the Members select thats what i was wanting to say. My bad if i wasnt clear.
Reply With Quote
  #117  
Old 01-21-2002, 05:42 PM
dabean dabean is offline
 
Join Date: Oct 2001
Posts: 247
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Arsenik
I was talking about the Users them selves and not only the Admin of the board.

I mean have the members edit their options and be able to use the settings the Admin selected by default or just not to use it at all if they dont want to. And also have the members be able to select what category they want collapsed or expanded like the Admin but in their own user options and be keept in the db since Collapsing and Expanding the forums on the fly doesnt work well. (the changes arent remembered)

Right now the hack keeps in the db the settings the Admin selects but not what the Members select thats what i was wanting to say. My bad if i wasnt clear.
Um no the users choice to expand or contract a forum is saved in the database with the hack as it exisits currently. This is in addition to admins being able to choose the forums to collapse by default. The the defaults are just that a user overridable default.

To make it clear exactly how this is achived I'll go through the function found in the current version line by line

PHP Code:
function dostatesaveXP (forumIDvalue) {
 var 
ifrm;
 if (
document.getElementById("colapser")) {  <- does the iframe element exist?
 
// okay iframe exists
  
document.getElementById("colapser").setAttribute("src""updateindex.php?s=$session[sessionhash]&fid="+forumID+"&val="+value);  <- set the iframe's SRC to load the preferance update.

  document.getElementById("colapser").style.visibility="visible"; <- make iframe visible
  document.getElementById("colapser").style.display="inline"; <- display iframe

  document.getElementById("colapser").style.visibility="hidden"; <- make iframe invisible
  document.getElementById("colapser").style.display="none"; <- hide iframe
 } else { <- no iframe exists lets make one :)
  ifrm = document.createElement("IFRAME"); <- create the iframe
  ifrm.setAttribute("id","colapser"); <- set its unque identifier
  ifrm.setAttribute("src", "updateindex.php?s=$session[sessionhash]&fid="+forumID+"&val="+value); <-  set the iframe'
s SRC to load the preferance update.
  
ifrm.style.width 80+"px"; <- make the iframe small
  ifrm
.style.height 30+"px"; <- make the iframe small
  
// ifrm.onload = hideframe; <- commented out, useless currently as IE doesn't support this
  
document.body.appendChild(ifrm); <- append the iframe into the document
  document
.getElementById("colapser").style.visibility="hidden"; <- make frame invisible
  document
.getElementById("colapser").style.display="none"; <- hide frame
 
}

Now for clarity the diference between display and visibility is display controls the box visiblity whilst visibility controls the element visiblity.. A display value of none with visibilty of visible would still leave the element visible, but out of "flow" with the other elements. Just like a display value of inline and visibility of hidden would hide the element but leave it's box behind leaving a empty "hole" in the page.
Reply With Quote
  #118  
Old 01-22-2002, 12:46 AM
philphee's Avatar
philphee philphee is offline
 
Join Date: Nov 2001
Location: boca raton, fl
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

dabean,

After I reread the instrustions and applied the changes specified to "forumhome_forumbit_level2_post" instead of "forumhome_forumbit_level1_post" it worked like a charm.

(Perhaps I should stop smoking crack :stupid: )

Thanks again for the great hack!!!
Reply With Quote
  #119  
Old 01-30-2002, 02:46 AM
mvigod mvigod is offline
 
Join Date: Dec 2001
Location: Jersey
Posts: 159
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just for clarity before I install this what exactly is Template_Option.txt in the instructions? What option does this refer to? Have no idea what you mean by

Quote:
If you have the forum, post, threads, template hack
Reply With Quote
  #120  
Old 01-30-2002, 12:26 PM
dabean dabean is offline
 
Join Date: Oct 2001
Posts: 247
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by mvigod
Just for clarity before I install this what exactly is Template_Option.txt in the instructions? What option does this refer to? Have no idea what you mean by

Basically that exention was provided as a request to cover sites with the template modification that adds a "header" to each grouping.
For a example Scroll back towards the begining somewhere around page 2 or 3 for posts by sirsteve.
Reply With Quote
  #121  
Old 01-30-2002, 05:03 PM
mvigod mvigod is offline
 
Join Date: Dec 2001
Location: Jersey
Posts: 159
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great hack!

Just installed it, followed the well written instructions and worked perfect on 2.2.1

I tested it on IE on the PC and it works fine...BUT...tried it on IE 5.0 on the Macintosh and when you collapse a forum all the forum titles, thread titles, descriptions and tables below the collapsed forum get squeezed to the left (take up maybe 30% of the left hand side of the table instead of running normally to fill the whole table left to right).

If you have a Mac with IE you can test it at my forum to see it.

http://www.rcuniverse.com

Any idea how to fix?

Also attached some images to match the default vbulletin style for anyone who wants them.

marc
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 05:37 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.04533 seconds
  • Memory Usage 2,327KB
  • 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)bbcode_php
  • (5)bbcode_quote
  • (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
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (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