Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- In Js:
- $.post("/artigo/favoritar/", function(data){
- alert(data.nome);
- }, "json");
- In php:
- public function favoritarAction()
- {
- $data = array(
- 'nome' => 'diogo',
- 'sobrenome' => 'alves'
- );
- return Zend_Json::encode($data);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement