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

Reply
 
Thread Tools
DI - BBCode [spoiler] Details »»
DI - BBCode [spoiler]
Version: 1.30, by D.Ilyin D.Ilyin is offline
Developer Last Online: Jun 2014 Show Printable Version Email this Page

Category: BB Code Enhancements - Version: 3.7.0 Rating:
Released: 05-07-2008 Last Update: 05-25-2008 Installs: 235
Uses Plugins Auto-Templates
Additional Files  
No support by the author.

DI - BBCode [spoiler] 1.30


Product information:
It's simple BBcode. But all of released here was too "difficult" to install . This one is very simple . It use jQuery javascript library v.1.2.3.
And can be usefull for large listing, for image hiding and so on...

Usage:
Code:
[spoiler=Custom header]some text
some text
some text
some text[/spoiler]
or
Code:
[spoiler]text
text
text
text[/spoiler]
Result on screen-01.gif

Installation information:
Files edit: 0
Templates edit: 0
Files to upload: 5
Time to install: less then 1 minute

Installation instructions:
  1. Upload all content in ./upload folder of plugin to your forum root directory
  2. Import XML file through ACP: Plugin System > Manage Products > [Add/Import Product]
  3. Optional: edit ./clientscript/vbulletin_css/spoiler.css to customize spoiler

Knowing problems:
  1. Not work if a quick reply or quick edit with AJAX functions was used for adding spoiler to post. You must reload page.

Tips:
  1. To edit default spoiler header when bbcode used without option - use that link ./admincp/phrase.php?do=edit&e[GLOBAL][spoiler_default_header]
  2. If you use english phrase and then translate it on your own language, you must rebuil post cache ./admincp/misc.php?do=buildpostcache
    (full instructions in screenshots see in this post from Ims)
  3. If you have very customized editor template (like in this post) and [SPOILER] button do not display you should add it manualy (if you want it of course ):
    • In Style manager ./admincp/template.php?do=modify open your style and choose Edit Temlates
    • Open editor_toolbar_on template
    • Find
      PHP Code:
      <if condition="$vBeditTemplate['extrabuttons'] != '' "
      and add it before
      PHP Code:
      <td><div class="imagebutton" id="{$editorid}_cmd_wrap0_spoiler"><img src="$stylevar[imgdir_editor]/spoiler.gif" alt="[SPOILER]" width="21" height="20" border="0" /></div></td

History:
Released: 1.00 - 09.05.2008
v.1.00 - first public release

Updated: 1.10 - 12.05.2008
v.1.10 - changed slide time to be faster
v.1.10 - changed place of deafault header phrase
v.1.10 - fixed bug with new thread preview with spoiler
v.1.10 - fixed bug with new reply preview with spoiler post

Updated: 1.20 - 21.05.2008
v.1.20 - added link to vbulletin.org modification thread
v.1.20 - added version check link
v.1.20 - added SPOILER button in advanced editor
v.1.20 - added spoiler.gif for advanced editor
v.1.20 - fixed bbcode parsing in WYSIWYG editor (post)
v.1.20 - added history.txt and readme.txt file

Updated: 1.30 - 26.05.2008
v.1.30 - added flash demo
v.1.30 - added usage help in bbcode list ./misc.php?do=bbcode (post)
v.1.30 - added support for announcements (post)
v.1.30 - made modification - Valid XHTML 1.0 Transitional


Please, click install if you like it!

Thanks for help: Marco van Herwaarden & Boofo

Show Your Support

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

Comments
  #92  
Old 07-25-2009, 05:59 PM
ArnyVee's Avatar
ArnyVee ArnyVee is offline
 
Join Date: Mar 2008
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Am I assuming correctly by thinking that I can limit the view of this mod to registered users only by editing the xml file?

If so, any tips on where I put the code?
Reply With Quote
  #93  
Old 07-26-2009, 01:38 PM
fly fly is offline
 
Join Date: Oct 2003
Posts: 1,215
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ArnyVee View Post
Am I assuming correctly by thinking that I can limit the view of this mod to registered users only by editing the xml file?

If so, any tips on where I put the code?
Not really. You'll want the 'hide' hack for that.
Reply With Quote
  #94  
Old 07-27-2009, 03:10 PM
itsheinz itsheinz is offline
 
Join Date: Feb 2009
Posts: 146
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

great mod..imma use it now
Reply With Quote
  #95  
Old 10-06-2009, 08:14 AM
Kirschtorte Kirschtorte is offline
 
Join Date: Jun 2009
Location: M?nsterland, Germany
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great job!

But there is a little bug i think.

1.) Create a spoiler and submit the Posting.
2.) Edit the spoiler and submit the changes.
3.) Now you will see, the spoiler doesn't work anymore. you can click, but nothing happens.

Only this two ways are possible to make the spoiler works again:

1.) reopen the page or
2.) refresh the browser window

That is not so good i find...
Reply With Quote
  #96  
Old 10-25-2009, 09:01 AM
Hubbitus Hubbitus is offline
 
Join Date: Nov 2005
Location: Russia
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hello, guys.

Fix spoiler on quick post/edit is quite trivial. Main what we must doing it is attach event handler not only to page ready, but to post add/change too.

Please see attached patches.

One additional note. In archive bundled 2 patches, first, called "quick-post|edit.old.patch" is "quick" fix. But I also suggest (really this idea was by Plague admin of imho.ws ) move function initSpoilers and its attachment to document ready event into external file to allow caching it by browser. And full changes present in "quick-post|edit.patch".

With best wishes, Pavel.
Reply With Quote
  #97  
Old 11-03-2009, 11:04 AM
MixFTW MixFTW is offline
 
Join Date: Oct 2009
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hi i got some prob with displaying spoiler img on editor bar:

P.S.: i tried all instruction in this tread but img still didnt appear.

Any suggestions?
Reply With Quote
  #98  
Old 11-03-2009, 11:28 AM
Hubbitus Hubbitus is offline
 
Join Date: Nov 2005
Location: Russia
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

What image now set for button? Adjust path to where you place it.
Reply With Quote
  #99  
Old 11-03-2009, 11:33 AM
Kirschtorte Kirschtorte is offline
 
Join Date: Jun 2009
Location: M?nsterland, Germany
Posts: 9
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hello,

you have to correct the path to the image. You can find it in the "spoiler.css" file in:
...yourforum/clientscript/vbulletin_css/spoiler.css
Reply With Quote
  #100  
Old 11-21-2009, 06:35 PM
Hell Bomb Hell Bomb is offline
 
Join Date: Jun 2009
Posts: 385
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

any change this becoming a 3.8 mod?
Reply With Quote
  #101  
Old 11-26-2009, 01:33 AM
Warlord's Avatar
Warlord Warlord is offline
 
Join Date: Jan 2002
Location: TN, USA
Posts: 668
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

To install this on the quick reply edit the showthread_quickreply template

Find:

PHP Code:
        <td><div class="imagebutton" id="{$editorid}_cmd_wrap0_quote"><img src="$stylevar[imgdir_editor]/quote.gif" width="21" height="20" alt="$vbphrase[wrap_quote_tags]/></div></td>
    </if> 
Add after:

PHP Code:
<td><div class="imagebutton" id="{$editorid}_cmd_wrap0_spoiler"><img src="$stylevar[imgdir_editor]/spoiler.gif" alt="[SPOILER]" width="21" height="20" border="0" /></div></td
EDIT: I created my own BB Code the old fashioned way and did not install this mod so to speak, but I don't see why it wouldn't work on 3.8

If not, just add the following BB Code.

In the Admin CP Click Custom BB Codes then select Add New BB Code. Fill in the blanks with this information.

Title: Spoiler
BB Code Tag Name: spoiler
Replacement:
HTML Code:
<div style="margin:5px 20px 20px 20px">

<div class="smallfont" style="margin-bottom:2px"><b>Spoiler:</b> 

<input type="button" value="Click to Reveal" style="width:100px;font-size:10px;margin:0px;padding:0px;" 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'; }">

</div>

<div class="alt2" style="margin: 0px; padding: 6px; border: 1px inset;">

<div style="display: none;">

{param}

</div>

</div>
Example: [spoiler]This text is Animation Spoiler[/spoiler]
Description: The [spoiler] tag allows you hide your text.

Make sure you upload the attached image to forumroot/images/editor.
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 06:18 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.04727 seconds
  • Memory Usage 2,335KB
  • 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
  • (2)bbcode_code
  • (1)bbcode_html
  • (4)bbcode_php
  • (1)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
  • (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