rendered paste body<?php
require('xajax/xajax_core/xajax.inc.php' );
//require('include/functions.php');
function favorite($username,$vid_id)
{
global $conn_id;
$faving = new xajaxResponse();
$faving->Alert("ok");
return $faving;
}
$xajax = new xajax();
$xajax->registerFunction("favorite");
$xajax->processRequest();
?>
<html>
<head>
<title>test page </title>
<?php $xajax->printJavascript('xajax/'); ?>
</head>
<body>
<div id="favi"><a href="javascript:void(0)" onClick="xajax_favorite('lolol','loolol');">test</a></div>
</body>
</html>