i’m getting dialogue box (Operation aborted)
What is the problem in this code?
<script type="text/javascript">
$(document).ready(function() {
$('.demo').popupWindow({
centerScreen:'1'
});
});
</script>
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You get the “Operation aborted” message in IE when JavaScript tries to modify the DOM (the structure of the HTML page) before IE’s rendering engine has finished processing it. The result is basically that the rendering engine crashes and you’re taken away from the page to an “Operation Canceled” error page.
The widely posted solution is to wait until the DOM has loaded, using a tool like FastInit, prototype’s
$(document).observe('dom:loaded'), or jQuery’s$(document).ready. But you are already using$(document).ready. So your code should work.I asked basically the same question here: IE7 "Operation Aborted" even with FastInit?
I accepted @NickFitz’s answer because not accepting an answer was causing my accept ration to go down and he provided the most useful information. Ultimately what I did was moved my script to right before the
</body>tag, and that seemed to solve the issue. Try that and see if it works for you. If you can’t actually move the script, wrap it in a function and call that function. I.E: