amiry jd
amiry jd

Reputation: 27585

How to call a function after dajax success?

here is my call:

<a href="#" onclick="Dajaxice.news.newspages(Dajax.process, {'p': {{ items.previous_page_number }},})" >prev</a>

How can I call a javascript function, after the ajax call success?

Upvotes: 1

Views: 476

Answers (1)

amiry jd
amiry jd

Reputation: 27585

I found the answer here. Cheers.

JAVASCRIPT

function my_callback(data){
    Dajax.process(data);
    // call my functions...
}

HTML

<a href="#" onclick="Dajaxice.news.newspages(my_callback, {'p': {{ items.previous_page_number }},})" >prev</a> 

Upvotes: 1

Related Questions