Class: pnHTML
Source Location: /pnHTML.phpInherited Variables
Inherited Methods
Class Details
[line 100]
HTML creation and display functions
This class is designed to make generating HTML output in Zikula very simple, and also allows for much greater control of output by the site administrator.
<strong>Example</strong>
// Information array
$colors = array(array('id' => 1,
'name' => 'Red',
'encoding' => 'ff0000'),
array('id' => 2,
'name' => 'Blue',
'encoding' => '00ff00'),
array('id' => 3,
'name' => 'Green',
'encoding' => '0000ff'));
// Create the HTML object and start it
$myhtml = new pnHTML();
$myhtml->Start();
// Add table showing encoding information
$myhtml->TableStart('Colors and Their Encodings', array('Color', 'Encoding'));
foreach ($colors as $color) {
$info = array($color['name'], $color['encoding']);
$myhtml->TableAddRow($info);
}
$myhtml->TableEnd();
// Add form to select a color
$myhtml->Text('<P><P>');
$myhtml->FormStart('colorchosen.php');
$myhtml->Text('Select a color: ');
$myhtml->FormList('chosen', $colorinfo);
$myhtml->FormSubmit('That\'s the color I want');
$myhtml->FormEnd();
// End the HTML object and print it
$myhtml->End();
$myhtml->PrintPage();
Tags:
[ Top ]
Class Methods
constructor pnHTML [line 168]
method BoldText [line 629]
method ConfirmAction [line 518]
|
composite function for generic confirmation of action
Tags:
Parameters:
[ Top ]
method EndPage [line 359]
|
Put the appropriate HTML tags in place to create a valid end to HTML output.
Tags:
[ Top ]
method FormCheckbox [line 1184]
|
Add HTML tags for a checkbox or radio button field as part of a form.
Tags:
Parameters:
[ Top ]
method FormEnd [line 938]
method FormFile [line 1220]
|
Add HTML tags for a file upload field as part of a form.
Tags:
Parameters:
[ Top ]
method FormHidden [line 1067]
|
Add HTML tags for a hidden field as part of a form.
Tags:
Parameters:
[ Top ]
method FormSelectMultiple [line 1120]
|
Add HTML tags for a select field as part of a form.
Tags:
Parameters:
[ Top ]
method FormStart [line 913]
|
Add HTML tags to start a form.
Tags:
Parameters:
[ Top ]
method FormSubmit [line 960]
|
Add HTML tags for a submission button as part of a form.
Tags:
Parameters:
[ Top ]
method FormText [line 995]
|
Add HTML tags for a text field as part of a form.
Tags:
Parameters:
[ Top ]
method FormTextArea [line 1034]
|
Add HTML tags for a text area as part of a form
Tags:
Parameters:
[ Top ]
method GetInputMode [line 229]
method GetOutput [line 292]
|
Return the HTML output from the buffer.
Note that this function does not clear out the object's buffer.
Tags:
[ Top ]
method GetOutputMode [line 187]
method Linebreak [line 646]
method Pager [line 395]
|
Tags:
Parameters:
[ Top ]
method PageTitle [line 577]
|
Add free-form text to the object's buffer as a title
Tags:
Parameters:
[ Top ]
method PrintPage [line 304]
|
Print the HTML currently held in the object.
Note that this function does not clear out the object's buffer.
Tags:
[ Top ]
method Redirect [line 482]
|
Redirect the user to another page
This function is broken, do not use it!
Tags:
Parameters:
[ Top ]
method SetInputMode [line 244]
method SetOutputMode [line 202]
method StartPage [line 331]
|
Put the appropriate HTML tags in place to create a valid start to HTML output.
Tags:
[ Top ]
method TableAddRow [line 854]
|
Add HTML tags for a row of a table.
Tags:
Parameters:
[ Top ]
method TableColEnd [line 800]
method TableColStart [line 783]
|
Add HTML tags for the start of a table column.
Tags:
Parameters:
[ Top ]
method TableEnd [line 834]
method TableRowEnd [line 817]
method TableRowStart [line 762]
|
Add HTML tags for the start of a table row.
Tags:
Parameters:
[ Top ]
method TableStart [line 716]
|
Add HTML tags for the start of a table.
Tags:
Parameters:
[ Top ]
method Text [line 556]
method Title [line 603]
|
Add free-form text to the object's buffer as a title
Tags:
Parameters:
[ Top ]
method UploadMode [line 271]
method URL [line 669]
|
Add HTML tags for a hotlink.
Tags:
Parameters:
[ Top ]
