Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Where is the spoiler button?

2»

Comments

  • peregrineperegrine MVP
    edited December 2014

    @Nozumi said:
    hello. i am looking to find out how to add a spoiler tag button to my forums. it can be with or without button bar.

    i read all this but am still very confused. is there a simple way to do this?

    yes, there is a simple way to do it, simply follow the steps.

    http://vanillaforums.org/discussion/comment/216519/#Comment_216519

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • hi, i did it via the markdown way and the spoiler tag works. but in button bar it does not show any icon for spoilers. is it supposed to? if so how come it not showing?

  • peregrineperegrine MVP
    edited December 2014

    @Nozumi said: hi, i did it via the markdown way and the spoiler tag works. but in button bar it does not show any icon for spoilers. is it supposed to? if so how come it not showing?

    they both work and both show icons, i suspect you didn't follow instructions correctly. therefore...

    here are some ideas for you...

    • read the suggestions afew times until you digest it.
    • follow the suggestions.

    if you have an issue....

    • state exactly what you did "do not say I did it all".
    • list exactly the steps you did. step by step in your own words.

    if the solution worked.

    state that the solution worked for you, in your followup.

    always a good idea to follow up all your discussions with a statement of what solved your problem. so other people can know whether the suggestions worked for you.

    you have left quite a few discussions dangling without a written response of followup.

    take a breather you are getting tired.

    http://vanillaforums.org/discussion/25115/how-to-how-can-a-new-user-better-help-the-community-when-asking-a-question

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • NozumiNozumi New
    edited December 2014

    ok i did the following in the following order

    install the latest spoilers plugin from github, enabled it

    changed from html to markdown

    $Configuration['Garden']['InputFormatter'] = 'Markdown';

    change line 330 to this

     PrepareMarkdown: function(ButtonBarObj, TextArea) {
    ButtonBar.DisableButton(ButtonBarObj, 'underline');
    // ButtonBar.DisableButton(ButtonBarObj, 'spoiler');
    

    change line 627 to this

     case 'spoiler':
    $(TextArea).insertRoundTag('spoiler',{opener: '[', closer: ']'});
    // DISABLED
    // return;
    break;
    

    then i tried to see if spoiler icon shows, it did not.

    so i continued and did this.

    change line 321 to this

     PrepareHtml: function(ButtonBarObj, TextArea) {
    // ButtonBar.DisableButton(ButtonBarObj, 'spoiler');
    

    change line 516 to this

     case 'spoiler':
    $(TextArea).insertRoundTag('spoiler',{opener: '[', closer: ']'});
    break;
    

    checked again but no work

  • peregrineperegrine MVP
    edited December 2014

    are you sure you are not caching your js code.

    what formatter do you want and what is your goal?

    post a screenshot of your buttonbar including text box on this forum.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • yes it is not a caching issue

    formatter don't matter to me, i just switched to markdown cause the guide said to. goal just to get this to work n show button properly

    http://i.imgur.com/ao3qL3y.png

  • peregrineperegrine MVP
    edited December 2014

    post your image on the forum

    --- Use the last button and upload your image, so we don't have to go off site.

    I think you have corrupted things. since your image doesn't show an underline. so you are changing things the wrong way.

    download the vanilla core again and refresh the buttonbar plugin code with a new copy.

    don't make any changes.

    then enable spoilers plugin.

    then post a screenshot.

    then follow instructions again.

    then post screenshot after you make changes.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • NozumiNozumi New
    edited December 2014

  • see above.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • peregrineperegrine MVP
    edited December 2014

    spoiler button in my buttonbar is the ? the last button.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • blizeHblizeH ✭✭
    edited July 2015

    Thanks @peregrine, in your post above did you follow the instructions you posted here? http://vanillaforums.org/discussion/comment/216519/#Comment_216519

    Which file do I have to make those amendments too? Thanks :)

Sign In or Register to comment.