I have a JSON object:
[{"song_id":"17382","title":" Revolution","song_viewed":"6","FK_genre_id":"11","artist_id":"190","artist_name":"Crematory","album_id":"1507","album_name":"Revolution"},{"song_id":"17377","title":"Reign Of Fear","song_viewed":"6","FK_genre_id":"11","artist_id":"190","artist_name":"Crematory","album_id":"1507","album_name":"Revolution"}]
And I want to post this object to server using Jquery.post
function postData(dataObj){
$.post(url,{data:dataObj});
};
in my PHP, I decode this object
$dataObj = $_POST['data'];
$dataObj = json_decode($dataObj);
print_r($datObj);
but it looks like it doesn't work.
Anyone help me?