tags:

views:

26

answers:

0

this code loads the data

jQuery.ajax({
     type: "GET",
        url: "getOptionsJson.php",
        cache: false,
        dataType: "json",
        data: "config_id="+config_id,
        success: function(json) {
            jQuery.extend(dataArr, json.ajax);
            jQuery.extend(opts, json.ajax2);
            printResult(config_id);
        },
        error: function() {
         alert('Error. Please try again');
            location.reload();
        }
    });

this code generates it

<?php 
header('Content-type: application/javascript');
echo json_encode(array(
    "ajax" => array(1 => "test", 2 => "test 2"), 
    "ajax2" => array(1 => "test 3", 2 => "test 4")
);
?>

when im working on mac, everything goes fine, but today i tried it on widnows, and it doesnt work. the code flows like its success, but opts and dataArr are null

i tried all headers (application/json, text/html, etc) i checked if getOptionsJson.php is called correctly via mail function filnally firebug says that im getting response, but theres no content and file is just 1kb

i tried even changing datatype to xml, still fails

ie gives a hint, it says 'there's error on site' which reffers to 127 line of jquery file

any idea?