/    Sign up×
Community /Pin to ProfileBookmark

Problem run in Mozilla

Hi every one, I’m new here. I have this piece of code. Its working fine in IE however not working in Mozilla. i know there is a syntax that IE-only inside the script, but i really don’t know how to change it to make it cross browser.

[CODE]
Here the code..Please expert help me out. his code is not created by me. I just maintain it.

<SCRIPT TYPE=”text/javascript”>
<!–
Xoffset= 20; // modify these values to …
Yoffset= -30; // change the popup position.
var old,skn,iex=(document.all),yyy=-1000;

var ns4=document.layers
var ns6=document.getElementById&&!document.all
var ie4=document.all

if (ns4)
skn=document.dek
else if (ns6)
skn=document.getElementById(“dek”).style
else if (ie4)
skn=document.all.dek.style
if(ns4)document.captureEvents(Event.MOUSEMOVE);
else{
skn.visibility=”visible”
skn.display=”none”
}
document.onmousemove=get_mouse;
function popup(){
var content=”<TABLE WIDTH=320 BORDER=1 BORDERCOLOR=#999999 CELLPADDING=4 CELLSPACING=0 “+
“BGCOLOR=#f6f6dc><TR><TD ALIGN=left class=agenda>”+msg+”</TD></TR></TABLE>”;
yyy=Yoffset;
if(ns4){skn.document.write(content);skn.document.close();skn.visibility=”visible”;}
if(ns6){document.getElementById(“dek”).innerHTML=content;skn.display=”;}
if(ie4){document.all.dek.innerHTML=content;skn.display=”;}
}

function get_mouse(e)
{
var x=(ns4||ns6)?e.pageX:event.x+document.body.scrollLeft;
skn.left=x+Xoffset;
var y=(ns4||ns6)?e.pageY:event.y+document.body.scrollTop;
skn.top=y+yyy;
}

function kill()
{
yyy=-1000;
if(ns4){skn.visibility=”hidden”;}
else if (ns6||ie4)
skn.display=”none”
}
var msg = “<strong>Submit my test for grading</strong><br>” +
“You be able to view your score immediately after submitting the quiz for grading. ” +
“Click the submit button to proceed with the submission.”;

//–>
</SCRIPT>[/CODE]

⭕o:o

to post a comment
JavaScript

0Be the first to comment 😎

×

Success!

Help @nadiahkamil spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.18,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...