Skip to content

Instantly share code, notes, and snippets.

Created November 15, 2010 16:12
Show Gist options
  • Select an option

  • Save anonymous/700521 to your computer and use it in GitHub Desktop.

Select an option

Save anonymous/700521 to your computer and use it in GitHub Desktop.
// Ajax event request handler
SendAjaxRequest = function(Event)
{
YUI().use(
"io-base", "json",
function(Y)
{
var myScriptEvent = escape(Y.JSON.stringify(Event));
Y.on('io:complete', HandleAjaxResponse, Y);
Y.io("http://localhost/ScriptHandler.php?ScriptEvent=" + myScriptEvent, { method: "POST" });
}
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment