2

Is there a plugin that makes external links open in new window, BUT only on the pages or domains or links I specify?

  • 1
    what's the point? if you want target="_blank" on specific links why not just add it manually? – onetrickpony Jun 27 '11 at 4:49
  • 1
    yes dreamgrowers,if you got answer means just accept the answer and earn 2 points....:) – Ramkumar M Jun 27 '11 at 11:20
  • I have hundreds of outbound links which I would like to open in a new tab, but have exceptions be possible. I've seen plugins to make external links open in a new tab, but it's an all or nothing thing... – dreamgrowers Jun 28 '11 at 6:40
1

Simple Popup Plugin . this plugin helps to made external links open..WordPress Popup Scheduler

  • I have hundreds of outbound links which I would like to open in a new tab, but have exceptions be possible. I've seen plugins to make external links open in a new tab, but it's an all or nothing thing... – dreamgrowers Jun 28 '11 at 6:40
1

It's not that hard - depending where you want it:

<?php
/* Plugin Name: (#21153) Open links in new window/tab */

function wpse21153_open_new_window( $content )
{
    // Add all your statements, when a link has to open in a new tab, here.
    if ( is_page() )
        return link_add_target( $content );

    return $content;
}
foreach( array( 'content', 'excerpt' ) as $location )
    add_action( "the_{$location}", 'wpse21153_open_new_window' );

Not the answer you're looking for? Browse other questions tagged or ask your own question.