post not working
this is my jscript code:
when i run it i get no response and firefox webconsole is showing ok


    dataString = friendMediaArray; // array?
    var jsonString = JSON.stringify(dataString);
    $(function() {
                $("#xbut").click(function() {
                    
                    $.each($(':input').serializeArray(), function(i,field){
                        jsonString[field.name] = field.value; 
                    }); 
                    jQuery.ajax({
            type: "GET",
            async: true,
            url: 'catch.php',
            data: {type: "stream", namef: jsonString },
                  
    
            
            success: function (msg) 
                    { alert(data); console.log(data); },
            error: function (err)
            { alert(err.responseText)}
        });}); }); 

catch.php


    <?php 
    if($_GET['type']=='stream'){
        $obj = json_decode($_GET['namef']);
    
        for($i=0;$obj[$i];$i++){
        echo $obj[$i]->{'namef'}." ";
        }
    }
    
    ?>

i get undefined even with var_dump($_POST)
it seems like ther's nothing send

GRT robert





post not working
===

this is my jscript code:
when i run it i get no response and firefox webconsole is showing ok


    dataString = friendMediaArray; // array?
    var jsonString = JSON.stringify(dataString);
    $(function() {
                $("#xbut").click(function() {
                    
                    $.each($(':input').serializeArray(), function(i,field){
                        jsonString[field.name] = field.value; 
                    }); 
                    jQuery.ajax({
            type: "GET",
            async: true,
            url: 'catch.php',
            data: {type: "stream", namef: jsonString },
                  
    
            
            success: function (msg) 
                    { alert(data); console.log(data); },
            error: function (err)
            { alert(err.responseText)}
        });}); }); 

catch.php


    <?php 
    if($_GET['type']=='stream'){
        $obj = json_decode($_GET['namef']);
    
        for($i=0;$obj[$i];$i++){
        echo $obj[$i]->{'namef'}." ";
        }
    }
    
    ?>

i get undefined even with var_dump($_POST)
it seems like ther's nothing send

GRT robert




