Search code examples
javascriptxssgoogle-caja

Cajoling in Server Side


I read some page of google-caja wiki and interest to use that. My view of caja is that We can send some chunk of html(for example tag) to google-caja's server(cajoling service) and that cajole that html and content javascript then send to our page. finally loaded google-caja's javaScript provide virtual DOM for content javascript(in tag div). And many other option for it(for example disabling tag content js).

I want to use this capability(cajole) in server side. Load some html chunk. Then pass it as a String to caja.And insert returned cajole String with necessary js(for apply limitation) to my JAVA web application response.

-Html chunk which should be cajole loaded in server side or provided from DB and is A String -My web application's language is JAVA.

which jars and jses file needed? Start from which function?

Thank you.


Solution

  • The web.xml used in the Caja playground shows that the CajolingServlet and PrecajoleInfoServlet are used to get the service up and running.

    The ANT build file lists the set of JARs you need. The main one is ant-jars/pluginc.jar and the rest are 3rd-party dependencies.

    google-caja-discuss is a good place for questions too.