Solved

XHTML1 Strict: "Anchor targets new window" alternative

Posted on 2003-11-19
3
293 Views
Last Modified: 2013-11-19
Hi there,

In using the XHTML1 Strict DTD, the anchor element's target attribute (<a target="_blank">) has been deprecated.
If we can't use Javascript, whats an alternative to popping up a new window?

Don't know if there is a solution using plain-old HTML or CSS, I know its possible with JScript, but what if the user-agent has JScript disabled?

Thanks
nD
0
Comment
Question by:nDorfin
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 17

Accepted Solution

by:
dorward earned 250 total points
ID: 9777389
If you can't use JavaScript and you want to use Strict then there is NO WAY to force a new window on the user. New windows are not part of structure and therefore shouldn't be done with HTML (although obsolete markup can achieve the effect). New windows are certainly nothing to do with the way a page looks and are also impossible with CSS.

If you want to force new windows on users, use Transitional and the non-semantic target attribute, or use JavaScript (which is the correct tool for this sort of UI altering logic).

Better yet, let the *user* choose when they want to open a new window. <http://diveintoaccessibility.org/day_16_not_opening_new_windows.html>
0
 

Author Comment

by:nDorfin
ID: 9778302
Excellent site, thanks dorward - nice to see another perspective.
Sometimes I think new windows are needed, as u dont want to people to leave your site for another.  Sure, they can use the back-button, if they remember too, but your site is their focus.  Rather split the focus than change it.
0
 
LVL 17

Expert Comment

by:dorward
ID: 9778352
You might not want a visitor to leave, but if the visitor wants to go then they are not going to be happy when somebody tries to stop them. They have a back button, and bookmarks, and browser history record, and the option to open a link in a new window if they choose to.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Is your Office 365 signature not working the way you want it to? Are signature updates taking up too much of your time? Let's run through the most common problems that an IT administrator can encounter when dealing with Office 365 email signatures.
When crafting your “Why Us” page, there are a plethora of pitfalls to avoid. Follow these five tips, and you’ll be well on your way to creating an effective page.
In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question