$.ajax({ type: 'GET', url: 'my_script.js', dataType: 'script' });Or even simpler:
$.getScript(url, callback);You can do this in pure javaScript too. Search for "Ajax" here for more info.
$.ajax({ type: 'GET', url: 'my_script.js', dataType: 'script' });Or even simpler:
$.getScript(url, callback);You can do this in pure javaScript too. Search for "Ajax" here for more info.