HighDots Forums  

Re: how to get back the target

Javascript JavaScript language (comp.lang.javascript)


Discuss Re: how to get back the target in the Javascript forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Thomas 'PointedEars' Lahn
 
Posts: n/a

Default Re: how to get back the target - 07-03-2005 , 07:05 AM






David Dorward wrote:

Quote:
Jc wrote:
Do you mean to use "_blank" instead of "_new"? AFAIK, "_new" doesn't
have any special meaning

_new isn't allowed as a target name
Pardon?

Quote:
and causes browsers to perform error recovery.
Which browser is that badly b0rken that it does not allow for any target
name?

Quote:
Some may treat it as _blank,
Again, which browsers are you talking about?

Quote:
some may treat it as a name with no special features.
Which is correct, and I can see no harm in that. What's your point, anyway?


PointedEars


Reply With Quote
  #2  
Old   
David Dorward
 
Posts: n/a

Default Re: how to get back the target - 07-03-2005 , 07:41 AM






Thomas 'PointedEars' Lahn wrote:
Quote:
David Dorward wrote:
Jc wrote:
Do you mean to use "_blank" instead of "_new"? AFAIK, "_new" doesn't
have any special meaning

_new isn't allowed as a target name

Pardon?
http://www.w3.org/TR/html4/types.html#h-6.16

Quote:
and causes browsers to perform error recovery.

Which browser is that badly b0rken that it does not allow for any target
name?
How can a browser be broken if it can't cope with a document including
something expressly forbidden? And which bit of "error recovery" did you
miss anyway?

Quote:
some may treat it as a name with no special features.

Which is correct
No it isn't, the browser is supposed to ignore it altogether.

--
David Dorward <http://blog.dorward.me.uk/> <http://dorward.me.uk/>
Home is where the ~/.bashrc is


Reply With Quote
  #3  
Old   
Thomas 'PointedEars' Lahn
 
Posts: n/a

Default Re: how to get back the target - 07-03-2005 , 12:54 PM



David Dorward wrote:

Quote:
Thomas 'PointedEars' Lahn wrote:
David Dorward wrote:
Jc wrote:
Do you mean to use "_blank" instead of "_new"? AFAIK, "_new" doesn't
have any special meaning
_new isn't allowed as a target name
Pardon?

http://www.w3.org/TR/html4/types.html#h-6.16
Hmmm, yes, you're right. However, the HTML 4.01 Transitional DTD says

Quote:
!ENTITY % FrameTarget "CDATA" -- render in this frame --
[...]
target %FrameTarget; #IMPLIED -- render in this frame --
It appears that many (most?) UA vendors never read or took heed of that
part of the specification, only of the DTD. Unfortunately , "_new" is
perfectly valid CDATA and so straightforward markup validation does not
show it as an error. What a junk! -- Why did they not specify

<!ENTITY % SpecialTarget "_blank|_self|_parent|_top" -- special targets -->
<!ENTITY % FrameTarget "%SpecialTarget; | NAME" -- render in this frame -->

in the first place? :-(

Quote:
and causes browsers to perform error recovery.

Which browser is that badly b0rken that it does not allow for any target
name?

How can a browser be broken if it can't cope with a document including
something expressly forbidden? And which bit of "error recovery" did you
miss anyway?
ACK, ACK. Although switched from "_new" to "_blank" (and then often from
"_blank" to no `target' attribute) long ago, apparently I missed that part
all the years, too. Thank you very much for pointing out!

Quote:
some may treat it as a name with no special features.

Which is correct

No it isn't, the browser is supposed to ignore it altogether.
ACK, ACK. However, many (most?) do not. But I agree that we should not
depend on that.


PointedEars
--
Alcohol and Math don't mix. So please don't drink and derive!


Reply With Quote
  #4  
Old   
David Dorward
 
Posts: n/a

Default Re: how to get back the target - 07-03-2005 , 03:32 PM



Thomas 'PointedEars' Lahn wrote:

Quote:
http://www.w3.org/TR/html4/types.html#h-6.16

Hmmm, yes, you're right. However, the HTML 4.01 Transitional DTD says
DTDs can only express certain constraints, you have to read the prose for
any specification.

Quote:
!ENTITY % SpecialTarget "_blank|_self|_parent|_top" -- special targets
--> <!ENTITY % FrameTarget "%SpecialTarget; | NAME" -- render in this
frame --
So "_blank", "_self", "_parent", "_top" OR a NAME token ... which would
include "_new"?

--
David Dorward <http://blog.dorward.me.uk/> <http://dorward.me.uk/>
Home is where the ~/.bashrc is


Reply With Quote
  #5  
Old   
Thomas 'PointedEars' Lahn
 
Posts: n/a

Default Re: how to get back the target - 07-03-2005 , 05:00 PM



David Dorward wrote:

Quote:
Thomas 'PointedEars' Lahn wrote:
http://www.w3.org/TR/html4/types.html#h-6.16
Hmmm, yes, you're right. However, the HTML 4.01 Transitional DTD says

DTDs can only express certain constraints, you have to read the prose for
any specification.
I already knew that, you should at least bother to try to read and
understand what I wrote.

Quote:
!ENTITY % SpecialTarget "_blank|_self|_parent|_top" -- special targets
--> <!ENTITY % FrameTarget "%SpecialTarget; | NAME" -- render in this
frame --

So "_blank", "_self", "_parent", "_top" OR a NAME token ...
Yes.

Quote:
which would include "_new"?
No. NAME tokens, in contrast to CDATA tokens, must begin with a
letter which in combination with the other values would both apply
to the specification's prose and allow for markup validation against
forbidden values, in contrast to the current DTD. For consistency,
the `name' attribute of `frame' elements should then be of type NAME,
too.

<http://www.w3.org/TR/html4/types.html#h-6.2>


PointedEars


Reply With Quote
Reply




Thread Tools
Display Modes

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

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



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.