WordPress.org

Ready to get started?Download WordPress

Forums

Link targets (7 posts)

  1. archshrk
    Member
    Posted 8 years ago #

    Is there a way to make links within my post "open in new window" without me having to manually add target=blank? That is, the ling tag automatically adds it. I'd also like to make the link to commentors' websites do the same but figure this is somewhere in the template, where should I look?

  2. MichaelH
    Member
    Posted 8 years ago #

    Podz has the answer for ya!

    http://www.tamba2.org.uk/wordpress/newwintag/

  3. niziol
    Member
    Posted 8 years ago #

    Greetings,

    I'm not sure if this may be helpful for what you are trying to do, but I use this plugin, called Zap_NewWindow which uses some javascript to automatically make all external links open in a new window and it seems to validate as compliant XHTML code.

    It works very well in both Firefox and IE (I'm assuming javascript must be enabled). Hopefully this is helpful for you!

    Cheers,
    Michael.

  4. pizzaman
    Member
    Posted 8 years ago #

    Here's the "non-validating", easier (maybe) way...

    <a href="http://whatever" target="_blank">TEXT</a>

    The target="_blank" part is what opens the new window.

  5. archshrk
    Member
    Posted 8 years ago #

    @MichealH I seem to be doing something wrong. I think the lines at 227 are going in the wrong place. Any help on where to place it would be great.

    @niziol, the plug in didn't seem to work for me.

    @pizzaman, I'm trying to avoid having to manually add that very thing.

  6. makemead
    Member
    Posted 8 years ago #

    Why force someone into opening a new window? It is annoying. If the end user wants an external link in a new window then let them decide to right click.

  7. vkaryl
    Member
    Posted 8 years ago #

    Matter of personal opinion (IOW speak for yourself john): I WANT new windows myself, it is NOT annoying, it's way easier if the site I'm on does it for me, regardless that I know how to force a new window (or tab as the case may be).

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags