Page Detail

The Website Page Detail is the heart of CMS. A Page Detail is the building block of a web page.

A page can have one or many page details of various content types. These page details are arranged in the content area in a table/row/cell structure, and can have different content types.

The shopping cart page pictured nearby shows five different page details, of different content types, that comprise the overall page.

Managing Data

The actual content and attributes for page details can be edited and accessed by first clicking the page folder to expand the list, and then clicking the corresponding pencil icon if the item you wish to edit. Page Details can be added by clicking the "add" link.

There are two required fields on this page (Position and Content Type). Which content type you choose will determine which other fields are required. These fields are described as follows:

  • Form - Shown above is an example of a List type content type. A Form is also selected. The form identifies the object related to the SQL query in the Content Information box below. A form is also selected here if you have chosen Form as the content type.
  • Control/File - If the content type selected is a Control or external File, the file path will be entered here.
  • Content Path - This field is used to specify the URL to iframe content. It is also used to enter text attributes for the above Control element.
  • Destination - If the content type is a Find control and results in a form submission, the destination must be specified with this drop-down. This is a list of existing pages in the website you are working on.
  • Wizard - If the content type is a wizard, the wizard would be specified in this drop-down.
  • Content Information - Depending on the content type and your HTML editor selection in your user preferences, you will see a Rich Text Editor, a WYSIWYG HTML editor, or just a text field. You will enter the content in this box.
  • Layout and Visibility Information - The arrangement, size and other attributes are specified in this area that determine position and placement of the page detail within the content area of the page.
  • Build ListContent - Build List Content is a tool that helps create quick queries by allowing you to simply select a table and columns. It is most often used to process search results.

Content Types

Content Type: the most critical setting. Content type determines the very foundation of the page detail. There are 7 content types:

HTML

An HTML content type is the simplest and most understood. Using the Rich Text Editor (RTE) you can insert text by typing or by pasting from another document. With the RTE you can select text and alter its qualities. By checking the Show HTML checkbox you can see and modify the HTML code directly. Note that if you are a code guru, you may want to turn the RTE off in your preferences because it will change the style and arrangement of HTML tags in the code. To insert images, you must first upload them to the web server and then reference them by file path in the code or RTE mechanism. The output of an HTML content type can be parsed if a form is specified.

Results can be parsed if you specify a Form.

Control

A Control is a ASP.NET Web User Control programmed element beyond a simple form or list element, although it may take the form of either. This content type is most often used as a search control, the list control (which adds additional functionality to the List content type), and the XslGenerator. A control is referenced by its file name.

eWeb contains the following built in user controls:

  • XslGenerator - a Control that transforms XML from the DynamicXmlBuilder or a web service through an Extensible Style Sheet (XSL) into readable HTML.
  • Find.ascx - a control that displays a Find page on a CMS web page detail.
  • ListControl - A List control enables you to type a SQL Statement and then output the results in HTML. Please note that this is different from the List SQL content type.
  • SiteSearchLineNoLabelTop.ascx - A simple, single search field that sends Get data to the destination. This particular control is designed to be used in a Default pane where the destination page selection is not available.
  • SiteSearchLineNoLabel.ascx - A simple, single search field that sends Get data to the destination. This particular control is designed to be used in the body of a page where the destination can be selected from the drop-down menu.

Wizard

A Wizard is a collection of one or more forms and/or HTML content in a series. A wizard offers some advantages over forms alone such as the positions, labels, visibility and target of buttons, as well as the ability to pass values through the process. The image nearby shows the first step in the Shopping Cart Wizard.

List

The list content type is one of the most commonly used to query the netFORUM database and output the results in HTML. The List allows you to insert SQL and perform queries against your netFORUM database. The format of a List page detail is the query first and then HTML markup to present the results. See main article for more.

IFrame

The iFrame content type allows you to insert an external web page into the space in the content detail. The functionality of this content type may be adequate, but more control of the iFrame attributes can be achieved by simply inserting an iFrame into an HTML content type.

File

A File content type allows you to insert a plain text file into a content detail. It works like an "include" and can be plain text or HTML. You will specify a (relative) path and file name in the content/file field such as:

~/eweb/docs/2010AnnualMeeting.htm

Ideally you should strip down the HTML to include only the content that would appear between the <body> tags, but don't actually include the <body> tags in the file.

Only standard HTML or HTM or Text files are supported; a Word document for example would not work.

Page Detail as Template

You can "include" one Page Detail in another Page Detail with the page detail key field. With this technique, you can define a particular page detail as a template, and then include that template on multiple pages. This can avoid the need to create and maintain duplicate page details.

For example, suppose you have a page detail with some text on it that explains the legal terms of a license agreement, and you want this page detail to serve as a template for use on several web pages. For the purposes of this example, we'll call this page detail the license agreement page detail.

First, you need to create this license agreement page detail so it can be included on other pages. After saving the page detail, edit it again and "copy" its detail key to your clipboard (see nearby screenshot for example).

Next, on the page you want the license agreement page detail to appear, add a page detail as you normally would, and in the page detail key, "paste" the key of the license agreement page detail you copied to your clipboard earlier.

When the web page renders, it will pull in the content from the license agreement page detail. You don't need to worry about setting the content type or any other fields other than layout information.

If you ever update the content of the license agreement page detail, it will automatically take effect on all the web pages that reference it.

Considerations for Page Detail Templates

Be aware that if a template page detail uses parsed values, those parsed values can function only in the context of the overall web page.

Organizing Page Detail Templates

To keep your library of templates organized, you might want to create a Web Section called "Templates", then add pages for each template with a descriptive name, and put your template page details within those pages. This way you can easily find the templates you need, and it will also emphasize the fact that a particular page details is in fact used as a template.

This section, and the pages in it, will never be viewed in the website; it is used solely for organizing templates.

Usage and Examples

You can use JavaScript functions on a Page Detail. See main article for more.