Source for file string.php
Documentation is available at string.php
@include '../include_path.php';
* Horizontal String ProgressBar example.
* @version $Id: string.php,v 1.1 2004/07/05 21:32:09 farell Exp $
* @author Laurent Laville <pear@laurent-laville.org>
require_once 'HTML/Progress.php';
$pkg = array ('PEAR', 'Archive_Tar', 'Config',
'HTML_QuickForm', 'HTML_CSS', 'HTML_Page', 'HTML_Template_Sigma',
'Log', 'MDB', 'PHPUnit');
$i = floor($progressValue / 10 );
if ($progressValue == 100 ) {
$msg = " installing package ($progressValue %) ... : ". $pkg[$i];
$bar = new HTML_Progress ();
$bar->setStringPainted (true ); // get space for the string
$bar->setString (''); // but don't paint it
$bar->setProgressHandler ('myFunctionHandler');
$ui->setStringAttributes ('width=350 align=left');
<title>Horizontal String ProgressBar example</title>
<?php echo $bar->getStyle (); ?>
background-color: #FFFFFF;
font-family: Verdana, Arial;
a:visited, a:active, a:link {
<script type="text/javascript">
<?php echo $bar->getScript (); ?>
<h1> <?php echo basename(__FILE__ ); ?></h1>
$bar->display (); // to display the last custom string (blank)
<p><< <a href="../index.html">Back examples TOC</a></p>
Documentation generated on Mon, 11 Mar 2019 13:52:39 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.
|