FORUM IS CLOSED. PLEASE USE QUESTIONS / ANSWERS PAGE INSTEAD
Login  |  Forum  |  Search   

Board index » Development » Feature requests




Post new topic Reply to topic  [ 4 posts ] 
 
Author Message
 Post subject: Valid XHTML strict for Link target _blank
 Post Posted: Tue Nov 15, 2011 7:49 am 
Offline

Joined: Wed Jul 27, 2011 10:12 am
Posts: 330
Location: Hong-Kong
Hello,

It's just a suggestion, may be it can lead to problems.

As all IP codes are valid - http://validator.w3.org/
the only one I found which is not is Target = _blank when you define a link in Rich/Text.
If a link is defined to open in a new page, the XHTML validation is invalid.

there is no attribute "target"
…t" href="http://www.apple.com" target="_blank">external</a> test. Valid XHML S…
You have used the attribute named above in your document, but the document type you are using does not support that attribute for this element. This error is often caused by incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Transitional" document type to get the "target" attribute), or by using vendor proprietary extensions such as "marginheight" (this is usually fixed by using CSS to achieve the desired effect instead).
How to fix: check the spelling and case of the element and attribute, (Remember XHTML is all lower-case) and/or check that they are both allowed in the chosen document type, and/or use CSS instead of this attribute. If you received this error when using the <embed> element to incorporate flash media in a Web page, see the FAQ item on valid flash.
http://validator.w3.org/docs/help.html#faq-flash
This error may also result if the element itself is not supported in the document type you are using, as an undefined element will have no supported attributes; in this case, see the element-undefined error message for further information.

http://www.alistapart.com/articles/flashsatay



Here are few solutions:
http://snipplr.com/view/2245/
Another one (not recommended by author of previous one)
http://snipplr.com/view/282/
some comments provides enhancements and links below other solutions...

Thanks


Top 
 Profile  
 
 Post subject: Re: Valid XHTML strict for Link target _blank
 Post Posted: Tue Nov 15, 2011 11:12 am 
Offline
Project Manager

Joined: Wed Nov 25, 2009 9:40 am
Posts: 421
We know that. And this is one of the reasons why we don't recommend using rich text widget. xHTML 1.0 strict do not support "target" attributes for anchors. The scripts you've showed are hacks, not solutions. Therefore, it's all up to you how to solve it. You can:
  • Not use that attribute
  • Change doctype to "transitional"
  • Add any of the scripts you need to apply those hacks


Top 
 Profile  
 
 Post subject: Re: Valid XHTML strict for Link target _blank
 Post Posted: Sun Mar 04, 2012 9:47 am 
Offline

Joined: Wed Jul 27, 2011 10:12 am
Posts: 330
Location: Hong-Kong
Just FYI, this script does not need any changes in the html, link are written exactly in the same way.

http://javascriptsource.com/snippets/op ... ndows.html


Top 
 Profile  
 
 Post subject: Re: Valid XHTML strict for Link target _blank
 Post Posted: Thu Mar 22, 2012 9:13 am 
Offline

Joined: Thu Mar 22, 2012 9:06 am
Posts: 1
I just clicked over from another site and figured I should take a look around. Like what I see so now I'm following you.


Top 
 Profile  
 
Display posts from previous:  Sort by  
 
Post new topic Reply to topic  [ 4 posts ] 

Board index » Development » Feature requests


 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: