[jQuery] Re: jQuery - Ajax and Load question

2009-07-07 Thread BaBna
You need to define your callback function. Maybe something like this? $.get(index.php, { id: productId , qtd: quantidade }, function(data) { doWhateverWith(data); }); On Jul 7, 10:42 pm, Glazz brunofgas...@live.com.pt wrote: Hello, I have a function that have this:                      

[jQuery] Re: jQuery - Ajax and Load question

2009-07-07 Thread James
with $.ajax, you use the success callback. $.ajax({ type: 'GET', url: 'index.php', data: 'id=' + productId + 'qtd=' + quantidade, success: function(data) {

[jQuery] Re: jQuery - Ajax and Load question

2009-07-07 Thread Glazz
Thanks for the quick replies, using $.get i can do what i want, with $.ajax i can too, except the data coming from the .php page is json encoded so in the $.get i used 'json' at the end - $.get(.., .., function(), 'json'); Is there any big difference using $.get or $.post, or just $.ajax and

[jQuery] Re: jQuery - Ajax and Load question

2009-07-07 Thread Glazz
Ok i got it, just need to use $.ajax({dataType : 'json'}); On 7 Jul, 23:12, Glazz brunofgas...@live.com.pt wrote: Thanks for the quick replies, using $.get i can do what i want, with $.ajax i can too, except the data coming from the .php page is json encoded so in the $.get i used 'json' at

[jQuery] Re: jQuery - Ajax and Load question

2009-07-07 Thread Cesar Sanz
$.get and $.post are convenient methods They both utilize $.ajax internally - Original Message - From: Glazz brunofgas...@live.com.pt To: jQuery (English) jquery-en@googlegroups.com Sent: Tuesday, July 07, 2009 4:12 PM Subject: [jQuery] Re: jQuery - Ajax and Load question Thanks