Skip to content

Instantly share code, notes, and snippets.

@mattiz
Created April 9, 2012 17:40
Show Gist options
  • Save mattiz/2344944 to your computer and use it in GitHub Desktop.
Save mattiz/2344944 to your computer and use it in GitHub Desktop.
<html>
<head>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript">
$(document).ready(function() {
var arr = [{test:'test'},{test2:'test2'}];
var data = {projects: arr};
$.ajax({
url: 'test.php',
type: 'POST',
dataType: 'json',
data: data,
contentType: 'application/json; charset=utf-8',
success: function(result) {
}
});
});
</script>
</head>
<body>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment