See also: developer documentation.

Installation

Copy the scripts you need from the Fcp.Website package to your Web folder. None of them is required. E.g. you can use just rsstatic.php to provide a newsfeed for a static website.

Getting started

Simply start creating content! Each file with the .html extension becomes a page in the website. The names of the files (sans extension) appear on the navigation menu in alphabetical order.

To create sub-pages, put them in a subdirectory named like the parent page, without the .html extension.

Since version 2009-10-10, pages sit in a subdirectory called content by default.

Configuration

Paste the code below into a file called website-cfg.php, in the same folder as the other scripts (a sample version is included in the archive). Modify the desired values. See explanations below.

<?php
// Name of your website; will appear in the title bar and as default header.
$SITE_NAME = 'Fcp.Website';
// Where are your HTML files located? Default is current directory.
$CONTENT_DIR = 'content';
// URL of external stylesheet, if any.
$CSS = null;
// File to include as header, if any.
$HEADER = null;
// File to include as footer, if any.
$FOOTER = null;
// File to include as sidebar, if any.
$SIDEBAR = null;
// URL of companion newsfeed script, if installed and desired.
$NEWSFEED = null;
// External template file, if any.
$TPL_FILE = null;
// Declare extra boxes, if any.
$BOXES = array();
?>

Configuration variables

$SITE_NAME
 
$CONTENT_DIR
 
$CSS
If you want a stylesheet of your own, put its URL in this variable. The URL should be server-relative or absolute. Note, FCP.Website won't check if the file is there.
$HEADER
 
$FOOTER
 
$SIDEBAR
 
$NEWSFEED
If you want the site to have a newsfeed (perhaps rsstatic.php), put its URL in this variable. See observations from $CSS.
$TPL_FILE
 
$BOXES
If you program new content boxes, add their names to this array. See Extensions below.

Extensions

The easiest way is by embedding PHP directly into your content. You can also extend Fcp.Website itself; see the source code for details.

Last modified: Sat 05 12 2009, 17:49:15 UTC