Jump to content
php.lv forumi
  • 0

uz IE met warningu


mach1ne^

Question

Lieta tāda, ka uz IE met erroru:

Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1;

Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR

3.0.30729; Media Center PC 6.0; InfoPath.2)

Timestamp: Tue, 19 Oct 2010 16:24:03 UTC

Message: Object required

Line: 10

Char: 1

Code: 0

URI: http://***.lv/new/js/page.js

 

page.js 10 rindinja:

if (document.all) {
document.onmousemove = captureMousePosition;
} else if (document.getElementById) {
document.onmousemove = captureMousePosition;
}
var mouse_x = 0;
var mouse_y = 0;
function captureMousePosition(e) {
if (document.all) {
mouse_x = window.event.x+document.body.scrollLeft+10; //sheit desmitaa rindinja
mouse_y = window.event.y+document.body.scrollTop+10;
}
else if (document.getElementById) {
mouse_x = e.pageX+10;
mouse_y = e.pageY+10;
}
}

 

Lieta tāda, ja, nav DOCTYPE, tad ir viss ok, bet nu negribētos ņemt nost to. :)

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"

"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

Edited by mach1ne^
Link to comment
Share on other sites

1 answer to this question

Recommended Posts

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...