Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(function(){
- var new_data = '';
- $.post('my_url', {}, function(data){
- new_data = data;
- });
- console.log(new_data);
- });
- $(function() {
- var new_data = '';
- $.post('my_url', {}, function(data) {
- new_data = data;
- console.log(new_data);
- });
- });
- $(function() {
- var new_data = '';
- $.post('my_url', {}, function(data) {
- new_data = data;
- response(new_data);
- });
- });
- function response(new_data) {
- console.log(new_data);
- }
Add Comment
Please, Sign In to add comment