shortcut to content
Minnesota State University, Mankato
Minnesota State University, Mankato

Latest information about COVID-19 and the campus community

×

HTML Page

Page address: https://web.mnsu.edu/its/web/editing/template/documentation/htmlpage.html

HTML Page Example

Here is an example of a HTML page that uses SiteMaster for its navigation:

<?php require_once($_SERVER['SMARTBUILDER']); $version=1;
$master='/directory_master_file_is_in/';
$contentcolumns=1;
$rightmenutitle='*Page Contents:[]';
$rightmenu[]='*Anchor link[#link one]';
$rightmenu[]='*Anchor link[#link two]';
$rightmenu[]='*Anchor link[#link three]';
$rightmenu[]='*Anchor link[#link four]';
?>
<?php setup('header'); ?>
<?php place('header'); ?>
<?php place('menucolumn'); ?>
<?php place('menucolumn-end'); ?>
<?php place('content'); ?>
<!--CONTENT BELOW-->
<?php place('rightcolumn');?>
<?php place('rightcolumn-end');?>

<h2>First Headline</h2>
<p>Your content here>/p>
<!--CONTENT ABOVE-->
<?php place('content-end'); ?>
<?php place('footer'); ?>

MSU Logo Bar

Each MSU page is required to have the MSU Logo Bar. In order to aid MSU web developers, the MSU Logo Bar is automatically inserted into the page by the MSU Template application.

The MSU Logo Bar includes the MSU Logotype, which is a link back to the MSU homepage (Tier One); and the MSU Search box, which allows users to conveniently search the MSU website and directories from any MSU page.

MSU Navigation Bar

Much like the MSU Logo Bar, the MSU Navigation Bar is required on all MSU pages and is automatically inserted by the MSU Template application. The MSU Navigation Bar provides links to high-level (Tier Two) MSU web pages.

MSU Logo Bar and Navigation Bar Code

The Logo Bar and the Navigation Bar are inserted automatically into every MSU Template page. The line below tells the server how to process the web page, and is always the first line of an MSU Template web page:
<?php require_once($_SERVER['SMARTBUILDER']); $version=1;
The line cannot be deleted, and the version should not be modified at this point. No additional code is required to display the Logo Bar and the Header Bar.

Right Menu

$rightmenutitle='*Page Title[]';
$rightmenu[]='*First Anchor Link []';
The right menu is an optional feature. Unlike the left navigation, the right menu should only be used on pages with one-column layouts. The right menu is great for navigation within a page, for long pages.

Right Menu Syntax

In the example below the title of the right menu is "Page Contents". This is optional. If you do have a title you can only have one level of items in the right menu. If you omit the title you may have multiple levels like the left menu.
$rightmenutitle='*Page Contents:[]';
$rightmenu[]='*Anchor link[#link one]';
$rightmenu[]='*Anchor link[#link two]';
$rightmenu[]='*Anchor link[#link three]';
$rightmenu[]='*Anchor link[#link four]';

Text in Left Column

<?php place('menucolumn'); ?>
<p>Text</p>
<?php place('menucolumn-end'); ?>

To put text in the left column, locate the lines of code reading <?php place('menucolumn'); ?> and <?php place('menucolumn-end'); ?>. In between these lines, enter the text you would like to appear in the left column.

Master File Link

$master='/directory_master_file_is_in/';
This line links to the master.php file that has all the owner, left navigation, window titles, header titles, and breadcrumbs.

Number of Content Columns

$contentcolumns=1;
There can be one or two columns for content. One-column layouts are suitable for most of your pages. Two-column layouts ($contentcolumns=2;) are best used for "gateway" pages, where most of the content is just links to other pages. In this case it is best to put the links in both columns, to help minimize unnecessary scrolling.

Header Placement

setup('header');
place('header');

This should be placed at the very end of the first PHP tag. It will insert into your page: the purple MSU header bar, the yellow MSU navigation bar, subhead (if defined), left navigation, window title, page title and breadcrumbs. You need the first one to be able to use the SiteMaster page.

Content

Note: The highest level heading tag allowed in the content area is h2. H1 is already defined by the $headertitle variable.

Content Placement

<?php place('content');?>
Immediately following the place header command (or the left menu placement command, if present) the beginning of the content is defined:
<?php place('content');?>
<!--CONTENT BELOW-->
Anything between the lines above and the lines below is the content of your page.
<!--CONTENT ABOVE-->
<?php place('content-end');?>

Right Column

<?php place('rightcolumn');?>
<?php place('rightcolumn-end');?>

If you're using the right menu, you must tell the processing file to place the menu. The right menu will not be rendered if these placement commands are missing, even if you defined the right menu items in the header. The right menu is always placed within the content area:
<?php place('content');?>
<!--CONTENT BELOW-->
<?php place('rightcolumn');?>
<?php place('rightcolumn-end');?>

Anything between the lines above and the lines below is the content of your page.
<!--CONTENT ABOVE-->
<?php place('content-end');?>

Starting New Column

To start a new column first turn your attention to the top of you page within the php code. Look for the code line stating $contentcolumns=1;. This code must first be changed to $contentcolumns=2; to be able to add a column. The mixed column option under this does not need this change.

<?php place('contentcolumn-add');?>
If you're using a two-column layout, you must mark the end of the first and the beginning of the second column:
<?php place('content');?>
<!--CONTENT BELOW-->

First column content.
<!--CONTENT ABOVE-->
<?php place('contentcolumn-add');?>
<!--CONTENT BELOW-->

Second column content.
<!--CONTENT ABOVE-->
<?php place('content-end');?>

Mixed Column

<?php place('contentcolumn-split-begin');?>
<?php place('contentcolumn-split-separate');?>
<?php place('contentcolumn-split-end');?>

Use the mixed column when you would like to have both one column content and two column content on the same page. The code for a mixed column layout looks like this:

<?php place('content');?>
<!--CONTENT BELOW-->

One column content.
<!--CONTENT ABOVE-->
<?php place('contentcolumn-split-begin');?>
<!--CONTENT BELOW-->

First column content.
<!--CONTENT ABOVE-->
<?php place('contentcolumn-split-separate');?>
<!--CONTENT BELOW-->

Second column content.
<!--CONTENT ABOVE-->
<?php place('contentcolumn-split-end');?>
<!--CONTENT BELOW-->

Return to one column content
<!--CONTENT ABOVE-->
<?php place('content-end');?>

Ending Content

<?php place('content-end');?>
After writing all the contents required for the page this line of code should be inserted to mark the end of the contents.

Footer

<?php place('footer');?>
This is placed at the very end of the code. The footer contains the content owner information, as well as the MSU logo, the MSU utility Links, and page information.