O'Reilly logo

Professional Alfresco: Practical Solutions for Enterprise Content Management by Kevin Roast, Michael G. Uzquiano, Michael Farman, John Newton, David Caruana

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 9. How to Create a Web Script

WHAT'S IN THIS CHAPTER?

  • Understanding Web script components

  • Developing a Folder Listing Web script

  • Accessing Alfresco services

  • Debugging Web scripts

  • Creating the Knowledge Base Search Web script

In this chapter you'll discover how to create your own Web scripts. The Web Script Framework is designed with the developer in mind, aiming to make it as easy and quick as possible to create new Web scripts in order to construct a RESTful interface to the Alfresco Content Application Server.

Web scripts are implemented using lightweight scripting languages such as JavaScript and FreeMarker, so their development is not restricted to only those who know the Java language. One of the key advantages of using scripting languages is that minimal tooling is required. An example of this is that there is no need to compile or package a Web script implementation. This simplicity also removes the need for a complex development environment. In fact, Web scripts can be built using only a basic text editor or even just the Alfresco Explorer client.

Scripting also brings immediacy to the development of Web scripts by removing the painful steps of compilation and packaging. It is possible to quickly turn around implementation changes, which can be seen and tested just by refreshing your Web browser. This mode of development has become very attractive to the Alfresco community, making Web scripts a preferred approach to interacting with, integrating with, and extending Alfresco. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required