Pawtucket Directory Layout

From CollectiveAccess Documentation
Jump to: navigation, search

The Pawtucket installation package is a single directory designed to be "droppable" onto a web server for easy installation. The default directory structure is:

  • /app - contains much of the code that implements Pawtucket, with the exception of the views that define what the user interface looks like (these are housed in the /themes directory further described below). /app contains the following sub-directories:
    • /app/conf - contains all application configuration files with the exception of the bootstrap setup.php file located in the Pawtucket root directory.
    • /app/helpers - function libraries implementing various helpful functions used internally by Pawtucket.
    • /app/locale - contains GetText-format .po and .mo message catalogues used to localize the Provider user interface. The translations located here are used when no theme-specific translation for the current locale exist, or when no entry for a text exists in the theme-specific translation. (Theme-specific translations are located in themes/<theme name>/locale)
    • /app/models - contains classes defining interfaces to most database tables (which generally correspond on a 1-to-1 basis with data entities) in the Pawtucket schema. These classes are used to manipulate data in the database - virtually all write operations on the database take place through these classes.
    • /app/controllers - contains all action controllers - the classes that actually handle requests, invoke library and model methods and load views for display. All controller classes are organized into subdirectories under /controllers that mirror the structure of the URLs used to invoke them.
    • /app/lib - contains code libraries used by Pawtucket. It is divided into two subdirectories:
      • /app/lib/core - contains "core" libraries implementing generally useful functions in a manner not specific to Pawtucket. (Or to put it another way: core libraries are reusable across applications and make few, if any, assumptions specific to Pawtucket or CollectiveAccess).
      • /app/lib/ca - contains libraries implementing CollectiveAccess-specific functionality (alos used in Pawtucket).
      • /app/lib/pawtucket - contains libraries implementing Pawtucket-specific functionality.
    • /app/plugins - contains Pawtucket plugins - PHP classes you can write to extend Pawtucket with specialized functionality.
    • /app/tmp - a temporary directory used for queuing media for background processing, for housing of cache files, and for processing of uploaded batches of media. This directory must be write-able by the user the web server runs under, otherwise errors will occur.
  • /js - contains all Javascript libraries.
  • /media - contains all uploaded media (images, audio, video, PDF documents, etc.) and files derived from that media.
  • /support - contains graphics and style sheets for the system error screen.
  • /themes - contains the "views" defining what various parts of the Pawtucket user interface look like. You can have multiple view sets defining different look-and-feels for the software. Each set is contained in its own subdirectory. The standard Pawtucket package ships with a single default view set contains in /themes/default Within each set are various view directories, discussed in detail on the Styling Pawtucket-using themes page. There is also a conf directory within each theme that contains optional configuration files that override those in app/conf, and a locale directory that can override the standard translations.
  • /viewers - contains web-based viewing software for various types of media.

It also contains the following files (not including informational README and licensing text files):

  • index.php - the "front controller" of the system; all requests go through this PHP script and are subsequently dispatched to action controllers in /app/controllers using information specified in the URL.
  • setup.php-dist - the distribution copy of the bootstrap configuration file used by the application to find its components and configuration files. The distribution copy is meant to be copied to setup.php and modified to suit the installation.

sphinx

Namespaces

Variants
Actions
Navigation
Tools
User
Personal tools