Support » Fixing WordPress » Auto-add target="_blank" and rel-"nofollow" to links.

  • Back in WordPress 2.X, I was able to edit line 369 of the quicktags.js file to read as follows:

    edButtons[i].tagStart = '<a href="' + URL + '" target="_blank" rel="nofollow">';

    This allowed me to automatically, by default, include target=”_blank” and rel=”nofollow” in all my links.

    Unfortunatly I can’t seem to replicate this fix in WP 3.3.1. I edited line 572 of the dev file to this:

    t.tagStart = '<a href="' + URL + '" target="_blank" rel="nofollow">';

    But that didn’t produce the desired result. Any ideas?

    And before anybody says anything, I know automatically opening in new windows is frowned upon, but it’s what my users want and it works best for this one individual site.

  • The topic ‘Auto-add target="_blank" and rel-"nofollow" to links.’ is closed to new replies.