The way it is:
var dados = $('#form').serialize(); // title=titulo&body=corpo
$.post("autosave.php", dados);
In PHP I get the values by reference as follows:
$title = &$_POST['title'];
and $body= &$_POST['body'];
Now when I try to do the same for:
$.post("autosave.php", {'meus_dados': dados});
and in PHP:
$title = &$_POST['meus_dados']['title'];
$body = &$_POST['meus_dados']['body'];
I get the following errors:
First error:
Warning: Illegal string offset 'title' in
Second error:
Fatal error: Can not create references to / from string offsets nor overloaded objects in ...