Page Layout Customization

From ReOS Documentation Wiki

Jump to: navigation, search

Contents

Main page layout

Following you can see the resulting layout of ReOS demo (Blueline) as is defined in configuration file. ReOS takes header, footer, left and right columns layout from the main layout, always that no specific page changes are defined.

caption


Home page layout

The home page layout takes header, footer, left and right columns layout from main page layout and adds its own changes to main layout.

File:Layout_2.jpg


How page layout works

caption
We can also change the "layout" of the HTML page. The page is divided into ReOS areas HEADERS, BLEFT, BRIGHT CENTRAL and FOOTERS.

We can remove or put any of the areas except CENTRAL. So we could have a HEADERS and CENTRAL, etc. ...

In each of these areas we can put a "block". A "block" is a php script that generates an XML output. The "blocks" that can be used are in the directory "/ blocks." The allocation of the "blocks" into each area is defined in the file "XML Navigator", "/ tpl/reos/nav2.xml." Each block output XML piece that should be defined in the XSL sheet for conversion to HTML.

XML Navigator File

Location : /tpl/reos/nav2.xml

Navigator Node : Contains one page node and many pg nodes.

pg Node : Contains nav nodes and blocks in headers, footers, central, bleft, bright nodes. It will define behavior in ReOS when node is executed and redefines de page layout defined in page node. Attribute name = Name of the node. Is the name of the php file executed by ReOS without extention.

nav Node: Contains one prev node and one action node. Prev = name of the node. Is the previous node executed by ReOS. Action = “reset” or “add”. Is the action taken by ReOS on navigation bar when pg node is executed.

Following are pg nodes are its use.


xslt node

<xslt> name of the xsl file without extentions</xslt>


pgtitle node

<pgtitle/> if is set, ReOS generates on output pgtiltle node that describes links of the current node.


msg node

<msg/> if is set, ReOS generates msg node that contains messages of ReOS (Error, Alerts, etc...)


headers | central | bleft | bright | footers nodes

< headers | central | bleft | bright | footers > Contains block nodes that define the nodes to be executed by ReOS and that will be placed within the node headers, central, bleft, bright or footers.


block node

Contains the name of the php file (Without .php extention) to be executed by ReOS.

mnu Node

It's node that help us to define html link to internal or external content.

<mnu>
<item link="pg=page&amp;htm=about">ABOUTUS</item>
<item link="pg=org">OFICINAS</item>
<item href="http://www.bcn.cat">"Barcelona"</item>
</mnu>

Item Attributes are :

link : is an internal link. The htm var is the xml file in /tpl/<theme_name>/content int this case about.en.xml for english. Then in link "pg=page&htm=xml_content_file" you have to change the xml_content_file without file extentions (Language.xml).

href : is an external link, to a html within your site or out.

Item values can be without quotes, then languange constant must be set up. For example, value ABOUTUS must have defined _ABOUTUS constant.

Item value with quotes will be the label of the link. When you test, uses quotes. When you want multilingual values, use constant name without quotes and first underline.


File:Navfile.jpg

Personal tools