Search code examples
jqueryfancybox

Permission Denied for jQuery script


All, I'm using the following code:

<head>
<title>Wedding Page</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Style-Type" content="text/css" />
<link href="style.css" rel="stylesheet" type="text/css" />
<link href="layout.css" rel="stylesheet" type="text/css" />
<!--<script src="js/jquery-1.6.4.js" type="text/javascript"></script>-->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js" type="text/javascript"></script>
<script src="js/cufon-yui.js" type="text/javascript"></script>
<script src="js/cufon-replace.js" type="text/javascript"></script>
<script src="js/Century_Gothic_400.font.js" type="text/javascript"></script>
<!--<script type="text/javascript" src="./fancybox/jquery.mousewheel-3.0.4.pack.js"></script>-->
<script type="text/javascript" src="./fancybox/jquery.fancybox.js"></script>
<link rel="stylesheet" type="text/css" href="./fancybox/jquery.fancybox.css" media="screen" />
<script type="text/javascript">
$(function() {
    $(".select_song").click(function(){
        event.preventDefault();
        song_id = jQuery(this).attr("id");
        song_id = song_id.split("_");
        song_id = song_id[1];
        $.post("save_song.php", { song_id: song_id, time: "2pm" },
            function(response) {
                $("#update_"+song_id).html(response.responseText1);
        }, "json");
    });

    $(".display_songs").fancybox({
        'maxWidth'    : 675,
        'maxHeight'   : 800,
        'fitToView'   : true,
        'closeClick'  : false,
        'openEffect'  : 'none',
        'closeEffect' : 'none',
        'scolling'    : 'no',
        'href'        : 'display_songs.php'
    });
});
</script>
</head>

Whenever I click on the display songs link (which has a class of display_songs) in IE I get the following error message:

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.3; .NET4.0C; .NET4.0E; MS-RTC LM 8; AskTbAD2/5.14.1.20007)
Timestamp: Sat, 14 Apr 2012 17:11:00 UTC


Message: Permission denied
Line: 4
Char: 2462
Code: 0
URI: https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js

Any idea why this is or how to fix it? Thanks in advance!


Solution

  • I actually had the jquery being loaded on my AJAX page. I removed it from there and now it works great.