File: sample6.php

Recommend this page to a friend!
  Classes of Tom Schaefer  >  Script Progress  >  sample6.php  >  Download  
File: sample6.php
Role: Example script
Content type: text/plain
Description: working with stylesheet
Class: Script Progress
Flush page output to show progress of server task
Author: By
Last change: bug fix
Date: 8 years ago
Size: 850 bytes
 

Contents

Class file image Download
<?php

include_once 'class.php';

/**
 * eight steps, each sleeps for 1 sec
 */
$buff = new ScriptProgress(8, 1000000);

$buff->addStylesheet();
# put some styles and a div-tag ahead
$buff->set("<div></div>");
# do some stuff here
$buff->next();


# second div
$buff->set("<div></div>");
# do some stuff here
$buff->next();

# third div
$buff->set("<div></div>");
# do some stuff here
$buff->next();

$buff->set("<div></div>");
# do some stuff here
$buff->next();

$buff->set("<div></div>");
# do some stuff here
$buff->next();

$buff->set("<div></div>");
# do some stuff here
$buff->next();

$buff->set("<div></div>");
# do some stuff here
$buff->next();

$buff->set("<div></div>");
# do some stuff here
$buff->next();


# end operation
$buff->set("<br>done");
# do some stuff here
$buff->next();


For more information send a message to info at phpclasses dot org.