MyBB Community Forums
[For 1.8] Spoiler MyCode - Printable Version

+- MyBB Community Forums (https://community.mybb.com)
+-- Forum: Extensions (https://community.mybb.com/forum-201.html)
+--- Forum: Plugins (https://community.mybb.com/forum-73.html)
+---- Forum: Plugin Releases (https://community.mybb.com/forum-102.html)
+---- Thread: [For 1.8] Spoiler MyCode (/thread-159302.html)

Pages: 1 2 3 4


Spoiler MyCode - Sephiroth - 2014-09-12

I have updated my spoiler bbcode to MyBB 1.8, and just want to announce it's availability on the new mods site .

I've also updated it to look better with the new default MyBB theme, as well as making it easier to expand/collapse the spoilers by clicking anywhere on the title row.

Enjoy!~


RE: Spoiler MyCode - ThePanda - 2014-09-13

Great, thank you very much for this plugin.

It works fine in Firefox but the +/- effect is not appearing in chrome. Possible bug? Please check attachment for screenshot.


RE: Spoiler MyCode - oji - 2014-09-15

Thank you, but it's better to use another regexp to support not only the English languge in descriptions. Something like this:

$pattern = array("#\[spoiler=(?:"|\"|')?(.*?)[\"']?(?:"|\"|')?\](.*?)\[\/spoiler\](\r\n?|\n?)#si", "#\[spoiler\](.*?)\[\/spoiler\](\r\n?|\n?)#si");



RE: Spoiler MyCode - Sephiroth - 2014-09-20

(2014-09-13, 09:16 AM)ThePanda Wrote: Great, thank you very much for this plugin.

It works fine in Firefox but the +/- effect is not appearing in chrome. Possible bug? Please check attachment for screenshot.

It works fine for me in Chrome; check your image path settings. Due to the way this plugin is coded with the javascripts, I believe it only pulls the min/max images from the images/ directory; if your theme uses a custom directory, simply drop collapse.png and collapse_collapsed.png into /images and you'll be fine.

[Image: JOAhlfa.png]




(2014-09-15, 12:26 AM)oji Wrote: Thank you, but it's better to use another regexp to support not only the English languge in descriptions. Something like this:




$pattern = array("#\[spoiler=(?:"|\"|')?(.*?)[\"']?(?:"|\"|')?\](.*?)\[\/spoiler\](\r\n?|\n?)#si", "#\[spoiler\](.*?)\[\/spoiler\](\r\n?|\n?)#si");


I will consider this for a future update, but seeing as I've only dealt with the English Language, I cannot guarantee proper support for non-english languages. If that regexp will work, I can include it in the next update. I'll likely see about custom theme support for this plugin, since I only run a single theme on my board.


RE: Spoiler MyCode - ThePanda - 2014-09-21

(2014-09-20, 10:49 PM)Sephiroth Wrote:
(2014-09-13, 09:16 AM)ThePanda Wrote: Great, thank you very much for this plugin.

It works fine in Firefox but the +/- effect is not appearing in chrome. Possible bug? Please check attachment for screenshot.

It works fine for me in Chrome; check your image path settings. Due to the way this plugin is coded with the javascripts, I believe it only pulls the min/max images from the images/ directory; if your theme uses a custom directory, simply drop collapse.png and collapse_collapsed.png into /images and you'll be fine.

Yes I'm using a custom theme. But the issue was not with the images.

The thing is that, the forum is in a "/forum" subdirectory.

In the plugin, I found that the

src="/images/collapse.png
src="/images/collapse_collapsed.png


So I replaced it with

src="forum/images/collapse.png
src="forum/images/collapse_collapsed.png


and now everything works fine. Thanks.  Big Grin


RE: Spoiler MyCode - fakhrul - 2014-09-26

working great!


RE: Spoiler MyCode - Eric - 2014-09-26

(2014-09-21, 06:11 AM)ThePanda Wrote:
(2014-09-20, 10:49 PM)Sephiroth Wrote:
(2014-09-13, 09:16 AM)ThePanda Wrote: Great, thank you very much for this plugin.

It works fine in Firefox but the +/- effect is not appearing in chrome. Possible bug? Please check attachment for screenshot.

It works fine for me in Chrome; check your image path settings. Due to the way this plugin is coded with the javascripts, I believe it only pulls the min/max images from the images/ directory; if your theme uses a custom directory, simply drop collapse.png and collapse_collapsed.png into /images and you'll be fine.

Yes I'm using a custom theme. But the issue was not with the images.

The thing is that, the forum is in a "/forum" subdirectory.

In the plugin, I found that the


src="/images/collapse.png
src="/images/collapse_collapsed.png


So I replaced it with


src="forum/images/collapse.png
src="forum/images/collapse_collapsed.png


and now everything works fine. Thanks.  Big Grin

Actually the plugin should probably be edited to this path:

src="images/collapse.png"



RE: Spoiler MyCode - Sephiroth - 2014-09-30

(2014-09-26, 03:56 AM)Eric J. Wrote:
(2014-09-21, 06:11 AM)ThePanda Wrote:
(2014-09-20, 10:49 PM)Sephiroth Wrote:
(2014-09-13, 09:16 AM)ThePanda Wrote: Great, thank you very much for this plugin.

It works fine in Firefox but the +/- effect is not appearing in chrome. Possible bug? Please check attachment for screenshot.

It works fine for me in Chrome; check your image path settings. Due to the way this plugin is coded with the javascripts, I believe it only pulls the min/max images from the images/ directory; if your theme uses a custom directory, simply drop collapse.png and collapse_collapsed.png into /images and you'll be fine.

Yes I'm using a custom theme. But the issue was not with the images.

The thing is that, the forum is in a "/forum" subdirectory.

In the plugin, I found that the



src="/images/collapse.png
src="/images/collapse_collapsed.png


So I replaced it with



src="forum/images/collapse.png
src="forum/images/collapse_collapsed.png


and now everything works fine. Thanks.  Big Grin

Actually the plugin should probably be edited to this path:


src="images/collapse.png"

Right, will fix that in the plugin itself. I run my board in the root directory, so I never caught that. Thanks.



e: Submitted new build to plugins site, labeled as Beta. If I get enough feedback from others with it, I'll bump it up to stable. Should contain fixes for non-english support in descriptions and non-root-directory forums. Still looking into getting theme image directory for the search/replace function inside of it so it can support boards with multiple themes.


RE: Spoiler MyCode - Vadim - 2014-10-03

Works thanks!
Write in the description "no button", you need to manually write the code:

[spoiler]This is a spoiler[/spoiler]

And I could not understand why there is no button, and how to add a spoiler.

Please add a button to the text editor.
And add styles to the plugin, so no need to add code to each theme.

Thank you!


RE: Spoiler MyCode - SwordSlayer - 2014-11-23

Which CSS file is the CSS supposed to go in?

When you open a template, there are many CSS files to choose from. I am not technical, so I need exact instructions. Thank you.