HTML_Progress::addListener

HTML_Progress

Prev |  | Next
HTML_Progress::addListener attachs a progress observer instance to the list of listeners ## Synopsis require_once 'HTML/Progress.php'; bool HTML_Progress::addListener( object $observer) ## Description This method is used to attach a progress observer or monitor instance to the list of listeners. ## Parameter object $observer the HTML_Progress_Observer instance to attach as a listener. ## Note ( HTML_Progress >= 1.0 )
| This function can not be called statically.
## See HTML_Progress::removeListener, HTML_Progress::getListeners ## Example

    <?php
    require_once 'HTML/Progress/monitor.php';

    $bar = new HTML_Progress();
    $mon = new HTML_Progress_Monitor();

    $li = $bar->getListeners();
    printf("try 1: %d listener(s) <br/>", count($li));

    $bar->addListener($mon);
    $li = $bar->getListeners();
    printf("try 2: %d listener(s) <br/>", count($li));
    ?>
Prev | Up | Next
HTML_Progress::setIndeterminate | Reference Guide | HTML_Progress::removeListener
Documentation generated on Sun, 12 Sep 2004 20:23:12 +0200 by phpDocumentor 1.3.0RC3