<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: What is typeof &#8220;unknown&#8221;?</title>
	<atom:link href="http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/</link>
	<description>Web development and Internet trends</description>
	<pubDate>Fri, 05 Dec 2008 10:47:17 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.1</generator>
		<item>
		<title>By: fornetti</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-397991</link>
		<dc:creator>fornetti</dc:creator>
		<pubDate>Sat, 30 Aug 2008 20:31:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-397991</guid>
		<description>I do not believe this</description>
		<content:encoded><![CDATA[<p>I do not believe this</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Robert Nyman</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-8017</link>
		<dc:creator>Robert Nyman</dc:creator>
		<pubDate>Thu, 31 Aug 2006 18:07:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-8017</guid>
		<description>Vojtech,

Thanks for sharing!

sudhakar,

Interesting!

Tom Trenka,

Very interesting reading. However, it seems that that can't be applied to everything, given &lt;a href="http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-5981" rel="nofollow"&gt;sudhakar's example&lt;/a&gt; above.</description>
		<content:encoded><![CDATA[<p>Vojtech,</p>
<p>Thanks for sharing!</p>
<p>sudhakar,</p>
<p>Interesting!</p>
<p>Tom Trenka,</p>
<p>Very interesting reading. However, it seems that that can&#8217;t be applied to everything, given <a href="http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-5981" rel="nofollow">sudhakar&#8217;s example</a> above.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tom Trenka</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-8001</link>
		<dc:creator>Tom Trenka</dc:creator>
		<pubDate>Thu, 31 Aug 2006 13:59:54 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-8001</guid>
		<description>Internet Explorer displays "unknown" when the object in question is on the other side of a COM+ bridge.  You may not know this or realize this, but MS's XMLHTTP object is part of a different COM+ object that implements IUnknown; when you call methods on it, you're doing so over a COM bridge and not calling native JavaScript.

Basically that's MS's answer if you try to test or access something that's not a true part of the JScript engine.

Before you complain about it further, bear in mind that MSXML was designed to be used from any MS platform, including VB and C++; there are methods and properties on XMLHTTP that are useless in scripting and even cause some confusion (such as the much maligned onreadystate, which makes plenty of sense once you realize that MSXMLHTTP, when used from C++ and VB, give you full interactive access to the internal IStream via the responseStream property.)</description>
		<content:encoded><![CDATA[<p>Internet Explorer displays &#8220;unknown&#8221; when the object in question is on the other side of a COM+ bridge.  You may not know this or realize this, but <acronym title="Microsoft">MS</acronym>&#8217;s XMLHTTP object is part of a different COM+ object that implements IUnknown; when you call methods on it, you&#8217;re doing so over a COM bridge and not calling native JavaScript.</p>
<p>Basically that&#8217;s <acronym title="Microsoft">MS</acronym>&#8217;s answer if you try to test or access something that&#8217;s not a true part of the JScript engine.</p>
<p>Before you complain about it further, bear in mind that MSXML was designed to be used from any <acronym title="Microsoft">MS</acronym> platform, including <acronym title="Visual Basic">VB</acronym> and C++; there are methods and properties on XMLHTTP that are useless in scripting and even cause some confusion (such as the much maligned onreadystate, which makes plenty of sense once you realize that MSXMLHTTP, when used from C++ and <acronym title="Visual Basic">VB</acronym>, give you full interactive access to the internal IStream via the responseStream property.)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: sudhakar</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-5981</link>
		<dc:creator>sudhakar</dc:creator>
		<pubDate>Wed, 12 Jul 2006 21:24:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-5981</guid>
		<description>I also found that IE returns 'unknown' when using 'typeof'.

It seems to happen in the following case:

Add html form elements (such as textboxes, drop down lists etc.) to a container (such as a div) dynamically using javascript and then reset container's innerHTML to empty (div.innerHTML = '').

Repeat this again, this time selecting enabling/disabling a few of the html form elements.

Next when you again add form elements to the DIV and try to access these elements by javascript, IE returns 'unknown' when using 'typeof'.

I believe this has got some thing to do clearing these elements from IE's DOM. Apparently setting innerHTML = '' does not seem do this as IE could not figure out using 'typeof'.</description>
		<content:encoded><![CDATA[<p>I also found that <acronym title="Internet Explorer">IE</acronym> returns &#8216;unknown&#8217; when using &#8216;typeof&#8217;.</p>
<p>It seems to happen in the following case:</p>
<p>Add <acronym title="HyperText Markup Language">HTML</acronym> form elements (such as textboxes, drop down lists etc.) to a container (such as a div) dynamically using javascript and then reset container&#8217;s innerHTML to empty (div.innerHTML = &#8221;).</p>
<p>Repeat this again, this time selecting enabling/disabling a few of the <acronym title="HyperText Markup Language">HTML</acronym> form elements.</p>
<p>Next when you again add form elements to the DIV and try to access these elements by javascript, <acronym title="Internet Explorer">IE</acronym> returns &#8216;unknown&#8217; when using &#8216;typeof&#8217;.</p>
<p>I believe this has got some thing to do clearing these elements from <acronym title="Internet Explorer">IE</acronym>&#8217;s <acronym title="Document Object Model">DOM</acronym>. Apparently setting innerHTML = &#8221; does not seem do this as <acronym title="Internet Explorer">IE</acronym> could not figure out using &#8216;typeof&#8217;.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Vojtech</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-5430</link>
		<dc:creator>Vojtech</dc:creator>
		<pubDate>Tue, 13 Jun 2006 10:15:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-5430</guid>
		<description>I met the "unknown" type when debugging one script working with an X3D Player. I had to write something like this:
&lt;code&gt;
function test(value)
  {
    if ((typeof value == "object") &#38;&#38; (value == null)) {value = "null";}
    if (typeof value == "undefined") {value = "really_undefined";}
    if ((typeof value.toString == "undefined") &#124;&#124; (typeof value.toString == "unknown")) {value = "no_toString";}
    return value + ":";
	}
&lt;/code&gt;
Without the third "if" I got "undefined" (no colon).</description>
		<content:encoded><![CDATA[<p>I met the &#8220;unknown&#8221; type when debugging one script working with an X3D Player. I had to write something like this:<br />
<code><br />
function test(value)<br />
  {<br />
    if ((typeof value == "object") &amp;&amp; (value == null)) {value = "null";}<br />
    if (typeof value == "undefined") {value = "really_undefined";}<br />
    if ((typeof value.toString == "undefined") || (typeof value.toString == "unknown")) {value = "no_toString";}<br />
    return value + ":";<br />
	}<br />
</code><br />
Without the third &#8220;if&#8221; I got &#8220;undefined&#8221; (no colon).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Robert Nyman</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2157</link>
		<dc:creator>Robert Nyman</dc:creator>
		<pubDate>Thu, 22 Dec 2005 08:00:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2157</guid>
		<description>Peter,

Yes, maybe just a bug. However, the &lt;code&gt;open()&lt;/code&gt; and &lt;code&gt;send()&lt;/code&gt; methods do work, even though they also return typeof "unknown", as opposed to the &lt;code&gt;abort()&lt;/code&gt; method that throws an error.

Weird...

Johan,

Thanks for the idea, although the line that goes wrong is when I want to check for support for the &lt;code&gt;abort()&lt;/code&gt; method.</description>
		<content:encoded><![CDATA[<p>Peter,</p>
<p>Yes, maybe just a bug. However, the <code>open()</code> and <code>send()</code> methods do work, even though they also return typeof &#8220;unknown&#8221;, as opposed to the <code>abort()</code> method that throws an error.</p>
<p>Weird&#8230;</p>
<p>Johan,</p>
<p>Thanks for the idea, although the line that goes wrong is when I want to check for support for the <code>abort()</code> method.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Johan</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2156</link>
		<dc:creator>Johan</dc:creator>
		<pubDate>Thu, 22 Dec 2005 03:48:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2156</guid>
		<description>Maybe it is a syntax error

typeof window.ActiveXObject != "undefined"

rewrite as (boolean operator):

typeof window.ActiveXObject !== undefined</description>
		<content:encoded><![CDATA[<p>Maybe it is a syntax error</p>
<p>typeof window.ActiveXObject != &#8220;undefined&#8221;</p>
<p>rewrite as (boolean operator):</p>
<p>typeof window.ActiveXObject !== undefined</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Peter Leing</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2150</link>
		<dc:creator>Peter Leing</dc:creator>
		<pubDate>Wed, 21 Dec 2005 15:49:51 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2150</guid>
		<description>Unless it is like Mats says, it may be a bug then. Microsoft's MSDN docs on Jscript only list the 6 typeof values you state.

&lt;a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/jscript7/html/jsoprtypeof.asp" rel="nofollow"&gt;JScript .NET typeof Operator&lt;/a&gt;

&lt;a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/script56/html/ee8a1036-119f-486f-b034-b07bdba87f0c.asp" rel="nofollow"&gt;JScript typeof Operator (JScript 5.6)&lt;/a&gt;

I also tried the type of .open and .send and got the same 'undefined' message back. It may just be that trying to get the typeof from an ActiveXObject's Method is not supported or working.</description>
		<content:encoded><![CDATA[<p>Unless it is like Mats says, it may be a bug then. Microsoft&#8217;s <acronym title="Microsoft Developer Network">MSDN</acronym> docs on Jscript only list the 6 typeof values you state.</p>
<p><a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/jscript7/html/jsoprtypeof.asp" rel="nofollow">JScript .NET typeof Operator</a></p>
<p><a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/script56/html/ee8a1036-119f-486f-b034-b07bdba87f0c.asp" rel="nofollow">JScript typeof Operator (JScript 5.6)</a></p>
<p>I also tried the type of .open and .send and got the same &#8216;undefined&#8217; message back. It may just be that trying to get the typeof from an ActiveXObject&#8217;s Method is not supported or working.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Robert Nyman</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2149</link>
		<dc:creator>Robert Nyman</dc:creator>
		<pubDate>Wed, 21 Dec 2005 15:13:01 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2149</guid>
		<description>Mats,

Yes, it sounds like a "not implemented" thing, I've seen that one too.

Rowan, Jens,

Yeah, maybe I should change ad provider... :-)
And yes, that web site looks pretty darn similar to the Mozilla web site.

Peter,

Yes, I've read that article, which is very good. And I guess his conclusion is right, that it's only necessary to abort calls in Mozilla.

Anyway, it doesn't explain Microsoft's own interpretation of what &lt;code&gt;typeof&lt;/code&gt; can return... :-)</description>
		<content:encoded><![CDATA[<p>Mats,</p>
<p>Yes, it sounds like a &#8220;not implemented&#8221; thing, I&#8217;ve seen that one too.</p>
<p>Rowan, Jens,</p>
<p>Yeah, maybe I should change ad provider&#8230; <img src='http://www.robertnyman.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /><br />
And yes, that web site looks pretty darn similar to the Mozilla web site.</p>
<p>Peter,</p>
<p>Yes, I&#8217;ve read that article, which is very good. And I guess his conclusion is right, that it&#8217;s only necessary to abort calls in Mozilla.</p>
<p>Anyway, it doesn&#8217;t explain Microsoft&#8217;s own interpretation of what <code>typeof</code> can return&#8230; <img src='http://www.robertnyman.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Peter Leing</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2147</link>
		<dc:creator>Peter Leing</dc:creator>
		<pubDate>Wed, 21 Dec 2005 13:47:15 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2147</guid>
		<description>Peter-Paul Koch had done some work with aborting XMLHTTP requests back in September. Maybe it will help you.

&lt;a href="http://www.quirksmode.org/blog/archives/2005/09/xmlhttp_notes_a_1.html" rel="nofollow"&gt;XMLHTTP notes: abort() and Mozilla bug&lt;/a&gt;</description>
		<content:encoded><![CDATA[<p>Peter-Paul Koch had done some work with aborting XMLHTTP requests back in September. Maybe it will help you.</p>
<p><a href="http://www.quirksmode.org/blog/archives/2005/09/xmlhttp_notes_a_1.html" rel="nofollow">XMLHTTP notes: abort() and Mozilla bug</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jens Wedin</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2144</link>
		<dc:creator>Jens Wedin</dc:creator>
		<pubDate>Wed, 21 Dec 2005 12:54:51 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2144</guid>
		<description>I know this does not have anyting to do with the article but I clicked the download now link. haha, what a joke, nice stealing from mozilla.org</description>
		<content:encoded><![CDATA[<p>I know this does not have anyting to do with the article but I clicked the download now link. haha, what a joke, nice stealing from mozilla.org</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Rowan Lewis</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2141</link>
		<dc:creator>Rowan Lewis</dc:creator>
		<pubDate>Wed, 21 Dec 2005 11:04:40 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2141</guid>
		<description>I wish I could help, but I can't :/

The reason I'm posting this is the ad under the article, it says:

"INSTANT DOWNLOAD ! - Download right now!"

Perhaps you should change ad provider...</description>
		<content:encoded><![CDATA[<p>I wish I could help, but I can&#8217;t :/</p>
<p>The reason I&#8217;m posting this is the ad under the article, it says:</p>
<p>&#8220;INSTANT DOWNLOAD ! - Download right now!&#8221;</p>
<p>Perhaps you should change ad provider&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mats</title>
		<link>http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2140</link>
		<dc:creator>Mats</dc:creator>
		<pubDate>Wed, 21 Dec 2005 10:24:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/2005/12/21/what-is-typeof-unknown/#comment-2140</guid>
		<description>Maybe it's related to the "not implemented yet" type ... ;)

I don't remember when I ran across it but I remember seeing it on one occasion.</description>
		<content:encoded><![CDATA[<p>Maybe it&#8217;s related to the &#8220;not implemented yet&#8221; type &#8230; <img src='http://www.robertnyman.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>I don&#8217;t remember when I ran across it but I remember seeing it on one occasion.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
