
Project Cenote (pronounced suh-noh-tee), was developed to demonstrate the ease with which applications can be built upon the Talis Platform.
Whilst it's easy for us to talk about how easy we think it is, or how great we think the Talis Platform is, we've decided it's better to show you. To that end Talis is providing the entire source code for our Project Cenote exemplar to you, for free (under the GPL License).
You can download the source in your preferred format here:
Here's a quick overview of technologies. Project Cenote is built in PHP5, running under Apache 2, and will run on either Linux or Windows based environments.
The distribution provided contains everything you need to get Cenote up and running locally. It is structured as follows:
cenote
- app
- conf
- src-graphics
The app folder contains all the PHP, JavaScript, CSS and XSLT code for Project Cenote. You need to point your Apache web server to this folder as the document root for the application.
The conf folder contains a file called rewrite.conf. This file specifies the Apache Rewrite Rules we use to map pretty URL's for the application.
The src-graphics folder contains the raw Adobe PhotoShop files we created when developing the graphics for the look and feel.
installation
In order to get Project Cenote running locally you'll need to setup your Apache web server to point to the application. The simplest way to do this is to unzip the distribution to your machine and then create a virtual host in Apache, for arguments sake let's say we want to call this virtual host "mycenote.talis.com". You can do this by adding the following to your httpd.conf file (this assumes you have unzipped the distribution to c:\cenote):
<VirtualHost mycenote.talis.com>
Include "C:/cenote/conf/rewrite.conf"
DocumentRoot "C:/cenote/app/"
ServerName mycenote.talis.com
</VirtualHost>
You'll need to add this line:
127.0.0.1 mycenote.talis.com
to your hosts file which is located:
- Windows: c:\windows\system32\drivers\etc\hosts
-
Linux: /etc/hosts
You'll need to enable the mod_proxy and mod_rewrite modules in Apache by editing your httpd.conf, simply uncommenting the following two lines:
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule proxy_module modules/mod_proxy.so
Finally, you'll also need to ensure that you have installed the appropriate PHP5 libraries, which you can do by following the instructions here for Windows and here for for Unix systems (including Linux).
about the application ...
In very simple terms the way the Project Cenote code works is to make requests to the platform for data, which the platform returns as XML (in fact it's RSS). Project Cenote then transforms that XML data using a couple of XSLT style sheets into HTML, to generate the User Interface.
You can get a feeling for the amount of effort involved in building Project Cenote by simply counting the number of lines of code. If we include all source files in the app folder and also the rewrite rules then there's only 600(ish) lines of actual code, the bulk of which is the two XLST stylesheets that generate the search results screen and the item details screen. It took two developers roughly three days to build the app, although if we're honest a lot of that time was spent arguing about how it should look; and for me as a developer that's a great position to be in.
If you don't want to install this code locally you can always try out Project Cenote at http://cenote.talis.com.