Skip to content

Instantly share code, notes, and snippets.

@ExperimentGarden
Created June 14, 2010 18:39
Show Gist options
  • Save ExperimentGarden/438076 to your computer and use it in GitHub Desktop.
Save ExperimentGarden/438076 to your computer and use it in GitHub Desktop.
<html>
<head>
<title>Ajax JavaScript Loader</title>
<script type='text/javascript' src='jquery-1.3.2.min.js'></script>
<script type='text/javascript'>
$.ajax({type: "GET",
url: "1_loader.js",
success: function(responseText)
{
eval(responseText);
internalFunction(); //This function defined in the JavaScript code loaded.
}
});
</script>
</head>
<body>
This is a basic test of loading JavaScript code via AJAX and then running it.
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment