Go Back   vb.org Archive > vBulletin Modifications > vBulletin 4.x Modifications > vBulletin 4.x Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Classic button 'Spoiler' BB Code (NO INSTALL REQUIRED) Details »»
Classic button 'Spoiler' BB Code (NO INSTALL REQUIRED)
Version: 1.00, by Fatal Hazard Fatal Hazard is offline
Developer Last Online: Nov 2023 Show Printable Version Email this Page

Category: BB Code Enhancements - Version: 4.x.x Rating:
Released: 10-30-2012 Last Update: Never Installs: 72
Re-useable Code Translations  
No support by the author.

This is a classic button spoiler BB Code.

Title: Spoiler

BB Code Tag Name: Spoiler

Replacement:
Code:
<div style="margin: 5px 20px 20px;"> <div class="smallfont" style="margin-bottom: 2px;"><b>Spoiler:</b>&nbsp;  <input value="Show" style="margin: 0px; padding: 0px; width: 45px; font-size: 10px;" onclick="if (this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = '';this.innerText = ''; this.value = 'Hide'; } else { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.innerText = ''; this.value = 'Show'; }" type="button" /> </div> <div class="alt2" style="border: 1px inset ; margin: 0px; padding: 6px;"> <div style="display: none;"> {param} </div> </div> </div>
Example: [Spoiler]Some Text[/Spoiler]


Description: Allows you to hide text or images.

Image Path: Choose an image and upload it to your server.

Use {option}: No

Remove Tag If Empty: Yes

Disable BB Code Within This BB Code: No

Disable Smilies Within This BB Code: No

Disable Word Wrapping Within This BB Code: No

Disable Automatic Link Parsing Within This BB Code: No

Preview:

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
5 благодарности(ей) от:
EliasAlucard, ka81, Mangahaven, zercosz

Comments
  #12  
Old 12-14-2012, 03:43 PM
fxdigi-cash fxdigi-cash is offline
 
Join Date: Jul 2012
Posts: 674
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This is something strange I just noticed. I placed the code in a plain html page to test it, and surprisingly it works fine without any issues. However, when I apply the same code to my vb bbcode, the show/hide button doesn't function...........

what do you think, mates?
Reply With Quote
  #13  
Old 12-14-2012, 07:20 PM
Fatal Hazard's Avatar
Fatal Hazard Fatal Hazard is offline
 
Join Date: Oct 2012
Location: Southampton, UK
Posts: 100
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hmm, I haven't experienced any issues with the code myself so I am just trying to think of why it wouldn't be working.
Reply With Quote
  #14  
Old 12-15-2012, 05:39 AM
fxdigi-cash fxdigi-cash is offline
 
Join Date: Jul 2012
Posts: 674
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi Fatal Hazard,

Thanks for the efforts on this mod. This is just a quick feedback about what's going on. I have two sites with different forums, so one in English and other one is non-English so the English one is fine with this mod and works great. However, the "Arabic" one is not functioning at the property "show/hide".... possibly there is something related to the language !!!

any idea?

Thanks in advance

Quote:
Originally Posted by Fatal Hazard View Post
hmm, I haven't experienced any issues with the code myself so I am just trying to think of why it wouldn't be working.
Reply With Quote
  #15  
Old 12-15-2012, 01:29 PM
Fatal Hazard's Avatar
Fatal Hazard Fatal Hazard is offline
 
Join Date: Oct 2012
Location: Southampton, UK
Posts: 100
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi, thanks for pointing this out. This may sound a bit weird but first have you tried editing the show and spoiler text in English to Arabic? This may be worth a try in the first instance.
If you haven't already, find:
Code:
2px;"><b>Spoiler:</b>&nbsp;  <input value="Show"
and edit the
Code:
''show"
into Arabic and
Code:
Spoiler:
into Arabic.
Reply With Quote
Благодарность от:
fxdigi-cash
  #16  
Old 12-15-2012, 01:48 PM
fxdigi-cash fxdigi-cash is offline
 
Join Date: Jul 2012
Posts: 674
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks @Fatal Hazard, for the infor. However, after many tries it didn't work. possibly there is something not correct. I tried also adding other bbcodes like Blink and didn't work on the Arabic forum. I will create a new version of Arabic version and add the Spoiler BBcode and see how things go. I will update the issue with the results.

Thanks.
Reply With Quote
  #17  
Old 12-15-2012, 02:37 PM
fxdigi-cash fxdigi-cash is offline
 
Join Date: Jul 2012
Posts: 674
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi again, it is me....

I just installed new Arabic version with the same code, and guess what! it works great. I believe there is something wrong with my current forum so I guess I need to replace it. Thanks the code works perfect.

Cheers
Reply With Quote
  #18  
Old 12-15-2012, 02:40 PM
Fatal Hazard's Avatar
Fatal Hazard Fatal Hazard is offline
 
Join Date: Oct 2012
Location: Southampton, UK
Posts: 100
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by fxdigi-cash View Post
Thanks @Fatal Hazard, for the infor. However, after many tries it didn't work. possibly there is something not correct. I tried also adding other bbcodes like Blink and didn't work on the Arabic forum. I will create a new version of Arabic version and add the Spoiler BBcode and see how things go. I will update the issue with the results.

Thanks.
Thanks, Truly Appreciated
Reply With Quote
  #19  
Old 12-15-2012, 02:51 PM
Fatal Hazard's Avatar
Fatal Hazard Fatal Hazard is offline
 
Join Date: Oct 2012
Location: Southampton, UK
Posts: 100
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by fxdigi-cash View Post
Hi again, it is me....

I just installed new Arabic version with the same code, and guess what! it works great. I believe there is something wrong with my current forum so I guess I need to replace it. Thanks the code works perfect.

Cheers
Great to hear!!!!
Reply With Quote
  #20  
Old 02-19-2013, 03:25 AM
hamdanikcung hamdanikcung is offline
 
Join Date: May 2012
Posts: 13
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

when installed this spoiler why in the mobile not working ??
any suggestion ?
Reply With Quote
  #21  
Old 02-19-2013, 09:33 AM
autoescala autoescala is offline
 
Join Date: Oct 2011
Posts: 101
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

works well, but only with text, the images can't be hidden! dont work with images
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 11:23 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.04689 seconds
  • Memory Usage 2,337KB
  • 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
  • (4)bbcode_code
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (5)post_thanks_box_bit
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (2)post_thanks_postbit
  • (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
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • 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