Our new Indie Games subforum is now open for business in G&T. Go and check it out, you might land a code for a free game. If you're developing an indie game and want to post about it, follow these directions. If you don't, he'll break your legs! Hahaha! Seriously though.
Our rules have been updated and given their own forum. Go and look at them! They are nice, and there may be new ones that you didn't know about! Hooray for rules! Hooray for The System! Hooray for Conforming!
Despite target being a deprecated element in XHTML strict 1.0, and a generally bad practice, I have a client website that wants links to external sites to open in a new tab/window. I've tried to push back on this, but they don't want people "taken away from their site".
So I've set target blank on a lot of links leading to other sides, but for some reason, independent of browser, the links are opening not just in a new tab, but in the original too.
It's a drupal site, and the primary use case is links created in the tinyMCE editor, but even when I tried to test it by hard-coding a link into the template files it still happens. Neither drupal or the editor are adding anything to the anchor tags.
I'm not looking for someone to solve this problem for me, just some ideas on where to look or what might cause this. If someone wants to look at one of the pages in question I can PM a link, though.
Some versions of IE have a (as far as I know unpatched) bug that ignores it entirely, but Firefox should open any link like this in a new tab. How's your formatting exactly? Should be:
<A HREF="url" TARGET="_blank">text</A>
If you missed a quote or used a ' somewhere, I think that would break it.
Some versions of IE have a (as far as I know unpatched) bug that ignores it entirely, but Firefox should open any link like this in a new tab. How's your formatting exactly? Should be:
<A HREF="url" TARGET="_blank">text</A>
If you missed a quote or used a ' somewhere, I think that would break it.
Use lowercase tags and attributes.
XHTML Strict will not accept the target attribute, XHTML Transitional will.
Otherwise you can use javascript to open them (if you have access to the rel attribute, you can put rel="external" then run JS to catch clicks on those links)
Posts
<A HREF="url" TARGET="_blank">text</A>
If you missed a quote or used a ' somewhere, I think that would break it.
XHTML Strict will not accept the target attribute, XHTML Transitional will.
Otherwise you can use javascript to open them (if you have access to the rel attribute, you can put rel="external" then run JS to catch clicks on those links)