What are Page Types?
‘Page Types’ in Pixelsilk are, in essence, types of data or content that can be displayed.
‘Page Types’ in Pixelsilk are, in essence, types of data or content that can be displayed. For instance, the default ‘Page Type’ for any web application is an HTML page; many content management systems may also offer an extended set of types (news, events, images).
Pixelsilk comes out-of-the-box with two predefined page types: ‘HTML Page’ and ‘List Section.’ What about things such as news and events that other CMS’s offer? It’s simple: Pixelsilk allows you to create new definable page types at any time, for any need.
New page types are always based on existing ones and are subsequently extended. The two base page types determine the functionality of new types, depending on the desired usage.
For example, an HTML page by itself consists (essentially) of free-form HTML content; that is, there are no constraints on the format or content of the HTML you are able to add to the page. This is fine for certain pages, but for others, you may want to force a specific layout or format—or just ensure that there is a specific page footer attached to a certain subset of pages.
For this purpose you would simply add a new page type, based on ‘HTML Page’. Then you would edit the properties of this new type, and modify the ‘Content Skin’ (yes, there’s that Skin handling again) to add the HTML you want re-used.
(A note here: the special system token [[Content]] needs to be used in the skin to include the actual page’s content; otherwise, the system would only render the static HTML present in the skin.)
From that point on, every new page (or section) added based on the new type you created would include the extra HTML you defined in the skin.
Page Types Slideshow Overview
List Sections
The ‘List Section’ page type in Pixelsilk is different from a “standard” HTML Page in that it allows you to create new types of data: articles, news, events, forms or any other type of record-based data.
(For database developers, creating a new List Section type is for all intents and purposes the same as creating a new table in the database, defining the fields in that table and optionally attached a set of behaviors and templates to each field.)
A common example is the creation of an article type. A typical article might have the following pieces of data attached to it:
- Title
- Author
- Date it was written
- Short description
- Full text of the article
- An image (if the full text doesn’t include HTML and images already)
Out of the box, Pixelsilk defines four default fields for any List Section type: Title, Image, BriefDescription, and FullDescription. (These are fields that can be modified but not deleted.) So when you are creating the new Article type, half the work is already done for you; you will only need to add an Author field, and a Date field.
Example 1.5

(You’ll notice two additional fields in Example 1.5 not mentioned above: the System fields DateTimeCreated and NumberOfViews. They are self-explanatory but beyond the scope of this example.)
The other component this new type is the Skins; these, as elsewhere in the system, are the templates by which Pixelsilk determines how to display the various components of the type. Inside of the skins, fields can be used as tokens by surrounding them in double brackets: [[Author]] and [[Title]], for example. The system will insert the content of those fields when displaying the data. And when used in a form context, the field tokens will be rendered as HTML form controls rather than straight content.
The skins give you full control over how the List Section content will be handled and displayed; they can contain HTML, CSS, JavaScript, and more. Furthermore, Pixelsilk lets you define (on a more “meta” basis) exactly how the List Section display should be handled—sorting options, pagination, filters on the data, and so on—on a section-by-section (or page-by-page) basis. Thus, you can create multiple pages of your new Articles type—and even though those pages share the same List Section properties, they can sort and display their article data in different ways.
Resources:
List-Section-Skins-Default.txt
Back to list...