Book Image

Learning Alfresco Web Scripts

By : Ramesh Chauhan
Book Image

Learning Alfresco Web Scripts

By: Ramesh Chauhan

Overview of this book

If you are an Alfresco developer who has no experience with web scripts and you want to start developing Alfresco web scripts, then this book is definitely for you.
Table of Contents (12 chapters)
11
Index

Deploying the web script


The web script components are now ready. In order to make them work together, these need to be deployed now. In your Alfresco installed directory, perform the following steps:

  1. Create a folder named example at the location tomcat\shared\classes\alfresco\extension\templates\webscripts.

  2. Put contentlocation.get.desc.xml, contentlocation.get.json.ftl, and contentlocation.get.xml.ftl at the location tomcat\shared\classes\alfresco\extension\templates\webscripts\example.

  3. Put custom-example-webscripts-context.xml at the location tomcat\shared\classes\alfresco\extension.

  4. Create folders com | example | content at the location tomcat\webapps\alfresco\WEB-INF\classes.

  5. Put the compiled Java class ContentLocationWebscript.class at the location tomcat\webapps\alfresco\WEB-INF\classes\com\example\content.

  6. Restart the server.

Registering the web script

As we just restarted the server, on a server startup, the web script gets registered. Now in order to confirm this, go to the URL http://localhost...