The `<Files>` section denies direct access to the template files from anywhere but the server itself.
The next section enables the rewriting engine and rewrites requests to `sapphire/main.php` if they meet the following
criteria:
* URI doesn't end in .gif, .jpg, .png, .css, or .js
* The requested file doesn't exist on the filesystem `sapphire/main.php` is called with the REQUEST_FILENAME (%1) as the `url` parameter and also appends the original
QUERY_STRING.
See the [mod_rewrite documentation](http://httpd.apache.org/docs/2.0/mod/mod_rewrite.html) for more information on how
mod_rewrite works.
## main.php
All requests go through main.php, which sets up the environment and then hands control over to Director.
**See:** The API documentation of `[api:Main]` for information about how main.php processes requests.