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.

Stop "Draft saved" information in InformMessage

Dr_SommerDr_Sommer Dr. of tender Programing ;) ✭✭
edited August 2014 in Vanilla 2.0 - 2.8

Ver. 2.1.1. Opera/FF/Chrome

Dear Community.. ;)

the save draft function is wonderful, but the information every minute about it in the InformMessage div is anoying...
How can I stop the prompt?

Doing this

     display: none;

is not working... also i think thats not correct, cause other informations in the InformMessage could be lost...

looked into the "Stop autodraft" plugin, but just got till "autosave.js", but no clue where is the Message sent to the InformMessage div...

So how can I stop only the "Draft saved" info?

ThX ;)


  • Options
    edited August 2014

    Not sure this is the 'proper' way to do it, but it'll work:

    Open the file applications/vanilla/controllers/class.postcontroller.php and look for the lines that say $this->InformMessage(T('Draft saved')); (there should be two lines, and there should be something else after 'Draft saved' but I don't remember what. You can comment that line out by adding // before it.

    Then upload the new version of the file in the same folder on your ftp and overwrite it.

  • Options
    Dr_SommerDr_Sommer Dr. of tender Programing ;) ✭✭

    ThX, Accent... that should be it... :)
    I know that's a nono messing with the forumcode, but if possible, this one could be my first Plugin... :smiley: just have to overcome my laziness and finally read the plugin Docs... :smiley:

  • Options
    BleistivtBleistivt Moderator
    edited August 2014

    @peregrine I was curious and tried this out. It works!

  • Options
    Dr_SommerDr_Sommer Dr. of tender Programing ;) ✭✭
    edited August 2014

    Ou maaann.... thought about that, but didn't try it out, thinking that an empty message Div would appear... :blush:

    but apparently you're right, peregrine... after changing it to "", NO popup shows, so your solution is even better... no messing around with the Forum Code... ;)

    ThX, Peregrine...

    Manual for noobs like me:

    1. open site_core.php in "Yourforum/locales/vf_de_DE (for german... other languages have other files!)
    2. find:
      $Definition['Draft saved at %s'] = "whathever"

    change it to:
    $Definition['Draft saved at %s'] = ""

    As for me:

    1. Don't philosophize stuff in your brain, ALWAYS try it out!!! :smiley:
    2. that was soo easy, no plugin needed for that... :smiley:
  • Options

    You can also set definitions dynamically.

    grep is your friend.

Sign In or Register to comment.