views:

23

answers:

1

I have having a problem with a jquery script showing up in every other browser except IE.

Below is a very very very simplified version of the script and this wont even show up. Please help Ive been working on this problem for about 2 weeks now

<script type="application/javascript">
    $.getTime = function(zone, success) 
    {
        var url = 'http://json-time.appspot.com/time.json?tz=' + zone + '&callback=?';
        $.getJSON(url, function(o){
                success(new Date(o.datetime), o);
        });
    };
</script>

calls the fuction to load library hours

<script type="application/javascript">
$.ajax({ type: "GET" ,url: "xml/LibraryHours.xml", dataType: "xml", success: function(xml){
                $.getTime('GMT', function(time)
                 {
                    $('<li/>').html('Work' ).appendTo('#update-target p');
                });}}); //close ajax{

then the update html area:

    <div id='update-target'>
     <!--<a href="#">Click here to load Library hours</a>-->
     <p></p> 
    </div>
+1  A: 

Shouldn't your tags have a type of text/javascript (e.g. type="text/javascript") instead of application/javascript?

Also, your script tag for your "jquery.min.js" has no type set.

Andy Evans
Work is whats being printed out normally it parses in library hours from the xml
Patrick Caldwell
yes that worked thank you. A simple "is it plugged in error" I guess I overlooked that little detail.
Patrick Caldwell