Patch (to be ported)
Project:
Bbcode
Version:
6.x-1.2
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
6 Apr 2011 at 23:19 UTC
Updated:
13 Jul 2011 at 01:05 UTC
Jump to comment: Most recent file
Comments
Comment #1
torgospizzaAttached is a patch that adds the pattern and replacement for [spoiler][/spoiler]. All it does right now is wrap it in a div - it might be good to create an additional CSS class (and a relevant patch) to set the background-color and font color to be all black by default, just so that spoilers appear hidden out of the box. (Alternatively we could do some kind of jQuery.toggle, which might be better for most cases.)
(Note: It looks like this patch also addresses some whitespace issues, which wasn't my intent; but if you examine it you'll see that all of the additional changes are that and nothing more; the line being added is the same as the line being deleted.)
As an FYI, my addition is on lines 73-75 of the patch:
Comment #2
StudioARE commentedI'm just using the spoiler module :)
http://drupal.org/project/spoiler
Comment #3
torgospizzaI found that too, but didn't want to install yet another module when the change only requires a few more lines of code. I've also found the spoiler module doesn't work in all instances (my patch probably doesn't either)... so it probably could use some work :)
Comment #4
Wooster commentedI'm sorry that I don't know how to use the patch file format. But I've created working spoiler tags that hide stuff.
I've marked anywhere I've edited anything with:
// Wooster
There are three of them, and all correspond to where the 'quote' tag lies.
You may be picky about my div classes and format, but I've provided the difficult part, and it suits my needs.