Jump to content

CCS: Pages Overview

The core of the CCS application centers around allowing you to create pages for your website. The way you create pages and the types of pages you create will be specific to your site, however the process is the same. One administrator may want to build the full front of their website using CCS, while another administrator may want to add some pages within the forums that are not there by default. Both scenarios can be covered by CCS.

The page manager interface looks similar to a computer folder view: you are presented with folders and files in a directory-style listing. You can create folders and subfolders, rename them, delete them, empty them, and move them around as needed. You can edit, rename, delete and move files within these folders as well. There is no built in limit to the number of folders or the directory tree depth imposed by CCS.

There are three page types that you can create: HTML, Javascript, and CSS. Javascript and CSS files are pretty straightforward - the main difference from HTML pages being that when you call to one of these files through a script, link, or import tag in an HTML document, CCS will output the correct HTTP header for the content type being served.

Actual pages can be edited as raw HTML, bbcode, or PHP; allowing you to do practically anything with your pages. You could make your page entirely dynamic, making use of IP.Board's database abstraction layer to retrieve data from the database, using the PHP page type. Or you could make a quick Terms of Service page to display to users using only the bbcode WYSIWYG editor. You can enter the actual filename, and a friendly name to describe the page. The folder and filename are combined to create the URL to reach the page, described later in this blog entry. You can also define the meta keywords and description tags when editing the page.

You can utilize page templates to make creating and editing pages simpler. We will be discussing page templates in a future blog entry, but in essence you would create a page template that defines the basic HTML structure, and then when adding a page you select the template you wish to use, select whether you want to import the template or just edit the page content itself, and the CCS will then be able to utilize pre-designed page templates to make page deployment much easier, faster, and more consistent.

Pages can be cached, helping to reduce overhead for pages that should be relatively static for all viewers. If your pages are very dynamic (for instance, they use a lot of feed or plugin blocks where content will differ from user to user) you should be careful regarding page caching. You wouldn't want an administrator to trigger some piece of the page to be recached with elevated permissions, for instance, showing topics a guest user wouldn't normally be able to view. If your pages are mostly static, however, pages can be built once, cached, and then served from cache on subsequent views. Remember that blocks can also be independently cached, so you can have relatively static blocks cached while leaving the page itself uncached (it will still used the cached HTML for blocks that specify to do so, and use dynamic HTML for blocks that have disabled caching). When you enable page caching, the entire page output is cached.

You can also define the permission masks needed to access a page, or allow all users to access the page. Using this, you can create moderator guidelines for your moderating team, or a contact information page for administrators, for example.

Actually accessing the page is an important matter, and many users will want to utilize friendly urls for this. There are many options built into CCS to handle this for you, which we will likely go over in more detail in a future blog entry. If you are accessing CCS through IP.Board, then CCS uses the built in friendly url functionality in IP.Board to generate friendly URLs (if enabled). Most people, however, will likely take our included index.php file, edit the path to their forums within it, and place this index.php somewhere else on the server. Using this method, you could place the website pages in a root directory of your domain, and have the forums contained within a /forums folder. You would then be able to manage your entire website, create virtual directories and pages, and more right in your IP.Board admin control panel easily. If your server supports mod_rewrite, you can create a .htaccess file and place it in the same directory as the index.php file provided with CCS, eliminating the /index.php/ from the URL entirely. Ultimately, you can define the urls entirely through the admin control panel by creating folders, defining the page names, and placing the pages within folders as you see fit.

As a traditional web server would do, if you visit a virtual folder but do not specify the file, an index.html will be looked for in that folder (you can change the file you wish to load by default in the settings). If the user requests a file that does not exist, a 404.html file will be looked for instead (again, the file is configurable in the settings). Nothing in the system requires you to use extensions, or requires extensions, when used, to be of a certain type. You could give your pages any extension you wish, or none at all (making pages appear to be "folders"). The system is extremely configurable to allow you to create pages for your site the way you want, and to appear in any way that you want. We've done our best to limit any restrictions in place so that you can define the website any way that you choose. Once you start creating pages, you'll be amazed at how simple and versatile the system really is to use.

  • Create New...