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

getStringAttributes Manual

returns attributes list of the progress bar string

by by Laurent Laville
mailto:pear@laurent-laville.org
November 2003, Laurent Laville
(HTML_Progress 1.0+)

Synopsis

mixed getStringAttributes( $asString )

Attributes

Name Type Default
asString boolean false

Description

The getStringAttributes() method is used to retrieve attributes of a progress bar string. Ouput could be an array or a string.

Example

Example below will show you the attributes definition of a progress bar string in two formats: array (default) and string.

  1. <?php
  2. require_once ('HTML/Progress.php');
  3.  
  4. $bar = new HTML_Progress();
  5.  
  6. $ui =$bar->getUI();
  7.  
  8. print '<pre>';
  9. var_dump($ui->getStringAttributes());         // see output 1.
  10. var_dump($ui->getStringAttributes(true));     // see output 2.
  11. print '</pre>';
  12. ?>

Output 1.

array(8) {
  ["id"]=>
  string(20) "installationProgress"
  ["width"]=>
  int(50)
  ["font-family"]=>
  string(37) "Verdana, Arial, Helvetica, sans-serif"
  ["font-size"]=>
  int(12)
  ["color"]=>
  string(7) "#000000"
  ["background-color"]=>
  string(7) "#FFFFFF"
  ["align"]=>
  string(5) "right"
  ["valign"]=>
  string(5) "right"
}
   

Output 2.

string(176) " id="installationProgress" width="50" font-family="Verdana, Arial, Helvetica, sans-serif" font-size="12" color="#000000" background-color="#FFFFFF" align="right" valign="right""
   

See Also

setStringAttributes Manual

Prev Up Next
setProgressAttributes Manual Reference Guides setStringAttributes Manual

Documentation generated on Mon, 11 Mar 2019 13:52:35 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.