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

Reply
 
Thread Tools
Accordion BBCode Details »»
Accordion BBCode
Version: 1337, by pimpery pimpery is offline
Developer Last Online: Aug 2006 Show Printable Version Email this Page

Version: 3.0.7 Rating:
Released: 02-15-2005 Last Update: 05-01-2005 Installs: 30
 
No support by the author.

This is a BBCode Addition that will add the [expand] BBCode to your forum.

The expand tag creates a expandable/collapsable container to hold your content and should be very handy when it comes to organizing tutorials or any other extensive posts.

To use it you would just do [expand=caption]content goes here[/expand]
To see the example, you can click on this link (to see the hack installed on an actual Vbulletin Forum)

Not only can text can be put in an accordion box. You can put anything that you would want in between the expand tags!

Before asking any questions please read the readme of which installation you want (manual or auto). The readmes explain all that is necessary for installing this add-on.

***UPDATE march 8th/2005:
modified the code to auto-expand if person viewing a box does not have javascript enabled. now only one installation is needed (accordion_install.php).
--
optimized javascript function to be quicker.
--
made installing even easier, now uses relative paths (no more search n' replace)
--

-Enjoy!, JaGx

Supporters / CoAuthors

Show Your Support

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

Comments
  #32  
Old 03-24-2005, 10:55 PM
news! news! is offline
 
Join Date: Mar 2005
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I made a modification so users can click the caption instead of the arrow image:

Code:
<div class='panel'><p onClick="expandit(this);"><a href="#">{option}</a></p><script>document.write("<div style=\'display:none;\'>");</script><noscript><div></noscript><br><table class='vbmenu_popup'><tr><td>&nbsp;&nbsp;<td>{param}</td><td>&nbsp;&nbsp;</td></tr></table><br></div></div>
are there any downsides to making this change?

How do I make a default [hide][/hide] that would have the caption: "click to reveal spoiler"?
Reply With Quote
  #33  
Old 03-25-2005, 03:49 AM
news! news! is offline
 
Join Date: Mar 2005
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by news!
I made a modification so users can click the caption instead of the arrow image:

Code:
<div class='panel'><p onClick="expandit(this);"><a href="#">{option}</a></p><script>document.write("<div style=\'display:none;\'>");</script><noscript><div></noscript><br><table class='vbmenu_popup'><tr><td>&nbsp;&nbsp;<td>{param}</td><td>&nbsp;&nbsp;</td></tr></table><br></div></div>
are there any downsides to making this change?

How do I make a default [hide][/hide] that would have the caption: "click to reveal spoiler"?
Thanks, but I figured this out. (I had to uncheck the Use {option})
Reply With Quote
  #34  
Old 03-26-2005, 11:11 AM
OrangeFlea OrangeFlea is offline
 
Join Date: Aug 2004
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I prefer to use input buttons (HTML), but how does one make it so the same button says "Show" and "Hide" (after the person clicks the button and the spoiler is shown)
Reply With Quote
  #35  
Old 03-26-2005, 06:28 PM
news! news! is offline
 
Join Date: Mar 2005
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Some of my users are getting this bug:
"When I click on a spoiler to reveal it, the screen shoots back to the top of the page."
Reply With Quote
  #36  
Old 03-27-2005, 07:34 AM
OrangeFlea OrangeFlea is offline
 
Join Date: Aug 2004
Posts: 208
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by k40tic
I know it was a line break is the reason i don't care. I never even really changes anything so in reality I never fixed anything. Actually never mind. I want a trophy for coming up with the easiest fix ever. The easy fix MVP trophy. I also want dancing bananas to come to my house and perform for my kids.
:banana: :banana:
Seriously though man this hack makes life easier for me so thanks.
It doesn't work for me for some reason. I still get the Error: expandit is not defined on the java console. I've even updated my java, so I don't know what the problem might be.

Second, how do I get mines to look/act exactly like this: Link
Reply With Quote
  #37  
Old 03-27-2005, 10:15 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by pimpery
alright thanks for the fix yoyooyyoyoyoyo, i did the fix in the attachments. so redownload if u havent yet.
The attachments still have it the old way.
Reply With Quote
  #38  
Old 03-27-2005, 07:12 PM
pimpery pimpery is offline
 
Join Date: Nov 2004
Posts: 103
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Boofo
The attachments still have it the old way.
Ok, sorry for the delay, but I didn't see anyone posted here!
Let me answer all your questions:
1) GAHHH! Why do people use the POUND sign as a link. Where did this stupid ass habit come from?!! POUND is the operator to signify to goto an anchor. Without anything following the pound operator, the link will just take the person to the top of the page.
News!!:
take away that pound crap and just use:
<p onClick="expandit(this);">{option}</p>

2) Boofo: yoyooyoy didn't do anything. My brother was the one who replied to him and thanked him.
Any javascript parser, would not take into account whitespace unless there was a bug in it. A linebreak doesn't matter. yoyoyo's problem was probably that he didnt update his cache on the browser, (i know from experience, 10+ pms for the same stupid thing)

3) OrangeFleas PM:
Quote:
Originally Posted by OrangeFlea
Pimpery! I love your accordion hack, but I was wondering if you knew how this site implemented the button:

http://boards1.wizards.com/member.php?u=310038

See how there's a hide and show button? How do I make mines exactly like that? Same button, same everything!

Thanks.
<-------------------REPLY---------------REPLY
REPLY---------------REPLY------------------->

They are using a different kind of spoiler thing that is way inefficient compared to mine.

Anyways, the way to do that would be for me to do it for ya!
Make sure you have the latest veresion of the Accordion BBCode Hack.

Goto BBCode manager and press edit on the expand bbcode

Find where it says:
<img src='cpstyles/vBulletin_3_Default/cp_expand.gif' border='0' onclick="expandit(this);">

Replace that with:
<input type='button' value='Show' onclick="if(this.value=='Hide'){this.value='Show'; }else{this.value='Hide';};expandit(this);">
Reply With Quote
  #39  
Old 03-27-2005, 10:26 PM
news! news! is offline
 
Join Date: Mar 2005
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks, that is great! The pound sign also makes the text a hotlink (i.e. the arrow turns into a pointing finger.

BTW if you want to know where I got the pound sign habit... Dreamweaver, I think I learned all my bad habits from using Dreamweaver. Don't get me wrong, I think it's one of the best at what it does (wyswyg html editor), but... it has made me lazy... Again thanks for this very useful hack and through implementing (and troubleshooting) it I've learned a lot about how vBulletin works (this is my first install... day four).
Reply With Quote
  #40  
Old 03-28-2005, 02:28 AM
pimpery pimpery is offline
 
Join Date: Nov 2004
Posts: 103
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by news!
Thanks, that is great! The pound sign also makes the text a hotlink (i.e. the arrow turns into a pointing finger.

BTW if you want to know where I got the pound sign habit... Dreamweaver, I think I learned all my bad habits from using Dreamweaver. Don't get me wrong, I think it's one of the best at what it does (wyswyg html editor), but... it has made me lazy... Again thanks for this very useful hack and through implementing (and troubleshooting) it I've learned a lot about how vBulletin works (this is my first install... day four).
no problem news. if you have any further questions feel free to ask!! ^_^
Reply With Quote
  #41  
Old 04-25-2005, 01:11 AM
pimpery pimpery is offline
 
Join Date: Nov 2004
Posts: 103
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

<img src='cpstyles/vBulletin_3_Default/cp_expand.gif' border='0' onclick="expandit(this);" style="cursorointer;">

Use style="cursorointer;" instead of <a href> tag to have the pointer be a hand when it goes over the arrow.
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 10:48 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.05421 seconds
  • Memory Usage 2,316KB
  • Queries Executed 26 (?)
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
  • (6)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
  • (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