Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 07-06-2010, 06:24 PM   PM User | #1
sohopigeon
New Coder

 
Join Date: Jun 2010
Posts: 31
Thanks: 4
Thanked 0 Times in 0 Posts
sohopigeon is an unknown quantity at this point
"target" attribute and "Strict" document type

Hi All,

Quick question I hope!

I get the error below when checking site on http://validator.w3.org/

my document type is W3C//DTD XHTML 1.0 Strict and I'm using a "target" attribute. (to open a new window to confirm email address for feedburner)

Is this error anything to worry about?

Should I change my document type to transitional? (I don't really understand the difference between the two and why you should chose one over the other).

thank you

Will

there is no attribute "target"
…t-align:center;" method="post" target="_blank" action="http://feedburner.googl…

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).

Last edited by sohopigeon; 07-06-2010 at 06:28 PM..
sohopigeon is offline   Reply With Quote
Old 07-06-2010, 08:01 PM   PM User | #2
Beagle
Senior Coder

 
Join Date: Jul 2005
Location: New York, NY
Posts: 1,084
Thanks: 4
Thanked 19 Times in 19 Posts
Beagle is an unknown quantity at this point
target is only used for framesets in strict mode. If you want to create a pop-up, you should use javascript, not target. The reasoning behind this is that creating a pop-up is a behavioral, not a structural, property. Markup is for structure, javascript is for behavior.
Beagle is offline   Reply With Quote
Old 07-06-2010, 08:04 PM   PM User | #3
sohopigeon
New Coder

 
Join Date: Jun 2010
Posts: 31
Thanks: 4
Thanked 0 Times in 0 Posts
sohopigeon is an unknown quantity at this point
thank you, I was just starting to think that, I'll re-post in the JavaScript forum for further help.

Will
sohopigeon is offline   Reply With Quote
Old 07-07-2010, 01:06 PM   PM User | #4
abduraooft
Supreme Master coder!

 
abduraooft's Avatar
 
Join Date: Mar 2007
Location: N/A
Posts: 14,678
Thanks: 158
Thanked 2,182 Times in 2,169 Posts
abduraooft is just really niceabduraooft is just really niceabduraooft is just really niceabduraooft is just really niceabduraooft is just really nice
Quote:
Originally Posted by sohopigeon View Post
thank you, I was just starting to think that, I'll re-post in the JavaScript forum for further help.

Will
No! You shouldn't cross post your issue in multiple forums as it's against forums rules. Instead, just request a moderator to move it to the right place (you may even use the report button).

Now, to your query, take a look at http://www.codingforums.com/showthread.php?t=152574, especially _Aero_'s reply.
__________________
Quote:
The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)
abduraooft is offline   Reply With Quote
Old 12-26-2012, 08:01 PM   PM User | #5
Greko
New to the CF scene

 
Join Date: Dec 2012
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Greko is an unknown quantity at this point
sorry for coming back here, but i dont understand very much these codes
how can i fix this

(you must use the "Transitional" document type to get the "target" attribute)

I use thiw instead
PHP Code:
"TARGET="_blank 
on my www.elgreko.gr

Thanks and sory for my english
Greko is offline   Reply With Quote
Old 12-26-2012, 08:36 PM   PM User | #6
felgall
Master Coder

 
felgall's Avatar
 
Join Date: Sep 2005
Location: Sydney, Australia
Posts: 5,447
Thanks: 0
Thanked 496 Times in 488 Posts
felgall is a jewel in the roughfelgall is a jewel in the roughfelgall is a jewel in the rough
target is ONLY valid in HTML 3.2 - it was deleted from HTML 4 so as to improve visitor experience by giving a greater choice. So to use it with any HTML 4 tags you MUST specify that the page is still transitioning from HTML 3.2. To complete the transition to HTML 4 you would remove the target attributes completely and let your visitors choose what opens in a new tab and what opens in a new window. Those more familiar with how their browser works will have it set to ignore the target attribute and open pages where they want them to anyway.
__________________
Stephen
Learn Modern JavaScript - http://javascriptexample.net/
Helping others to solve their computer problem at http://www.felgall.com/
felgall is offline   Reply With Quote
Old 12-26-2012, 08:49 PM   PM User | #7
Greko
New to the CF scene

 
Join Date: Dec 2012
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Greko is an unknown quantity at this point
oh yes you give me a good point, i was checkin this for 2 days without finding
a solution, i wil remove the target atributes.. hope all will be ok

and some last question please, if i want to include an icon lets say for Twitter
what code is better, can you please write one here

Thanks for your answer
Greko is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 06:36 AM.


Advertisement
Log in to turn off these ads.