Esmith::cgi

From SME Server

NAME

esmith::cgi - Useful CGI routines for e-smith server and gateway In a root terminal you can do the command below if you want to display the up-to-date content

perldoc esmith::esmith::cgi

VERSION

This file documents "esmith::cgi" version 1.4.0

SYNOPSIS

use esmith::cgi;

DESCRIPTION

This module contains a collection of useful routines for working with the e-smith manager’s CGI interface. =head1 WEB PAGE HEADER GENERATION ROUTINES

genHeaderNonCacheable($q, $confref, $title)

genHeaderCacheableNoPasswordCheck($q, $confref, $title)

genHeaderCacheableNoPasswordCheck($q, $confref, $title)

genHeader($q, $confref, $title, $expiry, $checkpassword)

genNavigationHeader($q)

genNoframesHeader($q)

genHeaderStartHTML($q)

WEB PAGE FOOTER GENERATION ROUTINES

genFooter($q)

genFooterNoCopyright($q)

genNavigationFooter($q)

genNoframesFooter($q)

FONT ROUTINES

curFont()

Returns the preferred font faces eg. "Verdana, Arial, Helvetica, sans-serif". This should be done by CSS now, so if you’re calling this, you shouldn’t be.

TABLE GENERATION ROUTINES

genCell($q, $text)

genDoubleCell($q, $text);

Generates a cell which spans two columns, containing the text specified.

genSmallCell($q, $text, $type, $colspan)

Generates a cell with "small" text (font size is 80%). "$type" can be one of: "normal" : creates cell "header" : creates cell

genSmallCellCentered($q, $text)

Generates a cell with "small" text (font size is 80%), centered. creates cell

genSmallCellRightJustified($q, $text)

Generates a cell with "small" text (font size is 80%), right justified. creates cell

genSmallRedCell($q, $text)

Generates a cell with "small" text (font size is 80%), left justified. creates cell

genTextRow($q, $text)

Returns a table row containing a two-column cell containing $text.

genButtonRow($q, $button)

Returns a table row containing an empty first cell and a second cell containing a button with the value $button.

genNameValueRow($q, $fieldlabel, $fieldname, $fieldvalue)

Returns a table row with two cells. The first has the text "$fieldlabel:" in it, and the second has a text field with the default value $fieldvalue and the name $fieldname.

sub genWidgetRow($q, $fieldlabel, $popup)

STATUS AND ERROR REPORT GENERATION ROUTINES

genResult($q, $msg)

Generates a "status report" page, including the footer

genStateError($q, $confref)

Subroutine to generate "unknown state" error message.

AUTHOR

Mitel Networks Corporation

For more information, see http://e-smith.org/