Support » Fixing WordPress » how do I add custom buttons to quicktags.js?

  • Back before about WordPress 2.7 or so it was easily possible to add buttons to the ones already there on the html editor. I used this to add things like this to it:

    edButtons[edButtons.length] =
    new edButton('ed_nofol'
    ,' rel="nofollow" '
    ); // special case

    This gave me a button that inserted ‘ rel=”nofollow”‘

    Later I did even better, I copied the code for the “link” button, renamed it NFLink, and made it create a nofolow link.

    Lately I’ve been trying to add these functions to WP 3.4.1. I have tried for hours to find a plugin that will do this (say by adding a checkbox to the add link popup giving the option to make the link nofollow)

    While I have found a few, none of them work and most haven’t been updated in a very long time.

    I did find one that works but it applies nofollow to every link in the post and that is not acceptable.

    I’ve been fighting with the completely unformatted nightmare of a spaghetti code mess that is quicktags.js for hours now and I’m ready to break something.

    Will someone PLEASE tell me how to do this thing that used to be so easy??

Viewing 1 replies (of 1 total)
  • Dittos Selif.

    I just upgraded an hour ago to 3.4.1 and found that quicktags.js isn’t written to handle the old style of quicktags.

    I had 40+ custom button that saved me hours each day coding my news portal. Now I’m back to square 1.

    I found 2 plugins: Jayj’s works but you can’t put the tags in an order that works for me. The other from Bueltge doesn’t work at all for me for some reason.

    I can’t think of any feature in WP more important than the post editors but to which there seems to be the least attention paid to.

    Customizable editor buttons is a make or break issue for me.

    Good luck!

Viewing 1 replies (of 1 total)
  • The topic ‘how do I add custom buttons to quicktags.js?’ is closed to new replies.