Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MacIntosh/JavaScript question

Status
Not open for further replies.

tboerner

Programmer
Oct 19, 2001
23
US
The following code fires for my PC (MS IE 5.0), but doesn't function for the Mac. Any ideas on what I can do?

<SCRIPT LANGUAGE=&quot;javascript&quot;>
var submitted;
submitted = false;
function window.onbeforeunload() {
if (submitted == false) {
return &quot;If you leave, changes will not be saved.&quot;;
}
}
</SCRIPT><
 
Correction: the code does fire on the Mac as well as on the PC. But, the Mac doesn't bring up a message box that the return statement does.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top