Closed Bug 557119 Opened 14 years ago Closed 14 years ago

typeof(document.createElement("object")) === "function", should be === "object"

Categories

(Firefox :: General, defect)

x86
All
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 268945

People

(Reporter: crass, Unassigned)

Details

User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.3pre) Gecko/20100316 Ubuntu/9.10 (karmic) Namoroka/3.6.3pre
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.3pre) Gecko/20100316 Ubuntu/9.10 (karmic) Namoroka/3.6.3pre

Normally, in javascript typeof(document.createElement(<element name>)) === "object", but when creating an html object element we get typeof(document.createElement("object")) === "function".  I believe this should be returning an object type.

Reproducible: Always

Steps to Reproduce:
1. Open firefox
2. Open javascript error console (Tools -> Error Console)
3. In the intput field put "typeof(document.createElement('object'))" and hit enter
Actual Results:  
"function" is in the output pane.

Expected Results:  
You should see "object" in the output pane.
Duplicate of bug 346789/bug 296858 -> Core bug 268945.
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.