function tinyurl() {
jQuery.ajax({
url: 'http://tinyurl.com/api-create.php?url=http://xxxxxxxxxxx/',
dataType: 'script',
success: function(response) {
welcomemsg(response.id);
}
});
}
function namie() {
jQuery.ajax({
url: 'https://xxxxxx.com/names?user=random,
dataType: 'jsonp',
success: function(data) {
welcomemsg(data);
}
});
}
function welcomemsg() {
jQuery.ajax({
url: 'https://xxxxx.com/posts?walmessage=Hello ' + data.name + ' your post has been posted '+ response.id +',
dataType: 'script',
success: function() {
}
});
}
我想得到tinyurl
andnamie
函数的响应,然后在函数中使用它们welcomemsg
。
我尝试使用参数但没有成功。