• Resolved Word

    (@hajar2901)


    “noopener” not added to links with target blank and I use a page builder, I succeed in adding it using Jquery but is there a way to add it using a function in functions.php ?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Moderator bcworkz

    (@bcworkz)

    You can use “the_content” filter. The filter callback would search for all occurrences of target="_blank" and replace finds with rel="noopener" target="_blank".

    Thread Starter Word

    (@hajar2901)

    Thank you, your answer helped me ^^

    Thread Starter Word

    (@hajar2901)

    🙂

    • This reply was modified 4 years, 8 months ago by Word.
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Add only noopener to external links’ is closed to new replies.