• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 457
  • Last Modified:

Correct invalid doctype with js

I have a script called in a page that generates a div with "position: fixed" (implemented in explorer even before IE7) but it doesn't work because the page doesn't have a doctype, it ignores the position:fixed.
There is a way to set the doctype with javascript?... even "rough" solutions are accepted ;)
(document.doctype is readonly!)

An example page without a doctype is this
http://support.microsoft.com/kb/214081
0
LAMASE
Asked:
LAMASE
  • 2
1 Solution
 
BadotzCommented:
Wht don't you just add a DOCTYPE to the page?
0
 
LAMASEAuthor Commented:
obviously i can't control the page, only the js ;)
0
 
BadotzCommented:
Obviously, some things are not possible ;-)
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now