|
|
|
|
File: [Development] / advokit-installer-bak / HtmlDisplay.class.php
(download)
/
(as text)
Revision: 1.2, Thu Jul 8 12:58:55 2004 UTC (6 years, 2 months ago) by travislow Branch: MAIN CVS Tags: r1-1-1-alpha-00, r1-1-0-alpha-00, r0-9-5, r0-9-0, r-0-8-5, r-0-8-2, r-0-8-1, r-0-8-0, HEAD Changes since 1.1: +23 -5 lines adding license. |
<?
# ======================================================================
# AdvoKit -- a campaign managment tool
# Copyright (C) 2004 OrchidSuites, Inc. (info@orchidsuites.net)
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the AFFERO GENERAL PUBLIC LICENSE
# as published by Affero, Inc.; either version 1
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# AFFERO GENERAL PUBLIC LICENSE for more details.
#
# You should have received a copy of the AFFERO GENERAL PUBLIC LICENSE
# along with this program; if not, write to Affero, Inc. at
# 510 Third Street - Suite 225, San Francisco, CA 94107, USA
# or visit <http://www.affero.org>.
# ======================================================================
# ======================================================================
# Display that uses included HTML. Probably should go away.
# ======================================================================
class HtmlDisplay extends BaseDisplay
{
var $htmlfile;
#.................................................. setFile
#
# Set the name of the file containing the HTML.
#
function setFile( $file )
{
$this->htmlfile = $file;
}
#.................................................. doRender
#
# Render this display.
#
function doRender()
{
$this->context->te->render( $this->displaytype.$this->context->config->get( "te_header_suffix", NULL ) );
$this->renderBody( $te );
$this->context->te->render( $this->displaytype.$this->context->config->get( "te_footer_suffix", NULL ) );
}
#.................................................. renderBody
#
# Render the meat of the display.
#
function renderBody( $te )
{
if( $this->htmlfile && file_exists( $this->htmlfile ) )
{
echo join( '', file( $this->htmlfile ) );
}
}
}
?>
| cvsadmin@voter2voter.org | CVS Snapshots (updated daily) |