HTML_Progress
[ class tree: HTML_Progress ] [ index: HTML_Progress ] [ all elements ]

Source for file horizontal_nostring.php

Documentation is available at horizontal_nostring.php

  1. <?php 
  2. @include '../../include_path.php';
  3. /**
  4.  * Horizontal no String ProgressBar example.
  5.  * 
  6.  * @version    $Id: horizontal_nostring.php,v 1.3 2004/04/18 13:25:43 farell Exp $
  7.  * @author     Laurent Laville <pear@laurent-laville.org>
  8.  * @package    HTML_Progress
  9.  */
  10.  
  11. require_once 'HTML/Progress.php';
  12.  
  13. $bar = new HTML_Progress();
  14. $bar->setAnimSpeed(100);
  15. $bar->setIncrement(10);
  16. $bar->setStringPainted(true);   // get space for the string
  17. $bar->setString('');            // but don't paint it
  18. ?>
  19. <html>
  20. <head>
  21. <title>Horizontal no String ProgressBar example</title>
  22. <style type="text/css">
  23. <!--
  24. <?php echo $bar->getStyle()?>
  25.  
  26. body {
  27.     background-color: #FFFFFF;
  28.     color: #000000;
  29.     font-family: Verdana, Arial;
  30. }
  31.  
  32. a:visited, a:active, a:link {
  33.     color: navy;
  34. }
  35. // -->
  36. </style>
  37. <script type="text/javascript">
  38. <!--
  39. <?php echo $bar->getScript()?>
  40. //-->
  41. </script>
  42. </head>
  43. <body>
  44. <h1><?php echo basename(__FILE__)?></h1>
  45.  
  46. <?php 
  47. echo $bar->toHtml()
  48.  
  49. do {
  50.     $bar->display();
  51.     if ($bar->getPercentComplete(== 1{
  52.         break;   // the progress bar has reached 100%
  53.     }
  54.     $bar->incValue();
  55. while(1);
  56. ?>
  57.  
  58. <p>&lt;&lt; <a href="index.html">Back examples TOC</a></p>
  59.  
  60. <h2>print_r </h2>
  61. <pre>
  62. <?php 
  63. print_r($bar->toArray())
  64. ?>
  65. </pre>
  66.  
  67. </body>
  68. </html>

Documentation generated on Mon, 11 Mar 2019 10:15:08 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.