我有一個jQuery的使用,從一個servlet如何從ajax成功函數調用方法?
<script type="text/javascript">
$(document).ready(function() {
$.ajax({
url:'ServiceToFetchDocType',
type:'post',
cache:false,
success: function(response){
//some data fetched from ServiceToFetchDocType
//Need to invoke another method here
}
});
</script>
獲取一些數據是否有可能調用成功函數內部的另一種方法,並得到一些價值AJAX? 我對jQuery和ajax非常陌生,任何幫助表示讚賞。
https://stackoverflow.com/questions/22233650/jquery-nested-ajax-calls-formatting – tech2017
是什麼阻止你調用方法? – Satpal
是的,你可以。 'succes:function(response){myFunction(response); });'... – TCHdvlp