On Fri, Mar 02, 2007 at 06:57:27AM +1100, Alec Thomas wrote:
> Something else to think about might be an AJAX API in Trac. More and more
> plugins are starting to use AJAX, so it might be useful to have this built
> into the core.
I've added a jsonrpc handler to the now inappropriately named XML-RPC plugin.
It lets you do things like this in JavaScript:
rpc = new $.jsonrpc("http://localhost:8080/stable/jsonrpc");
rpc.expose("wiki.getPageHTML");
$("#test").click(function() {
page_handler = function(content) {
$('#test').after(content);
}
rpc.server.wiki.getPageHTML(page_handler, "WikiStart");
}
Any method exposed through XML-RPC is also exposed through JSON-RPC, and normal
permissions apply.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac
Development" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/trac-dev?hl=en
-~----------~----~----~----~------~----~------~--~---