本文整理汇总了PHP中HTML_Progress::toHTML方法的典型用法代码示例。如果您正苦于以下问题:PHP HTML_Progress::toHTML方法的具体用法?PHP HTML_Progress::toHTML怎么用?PHP HTML_Progress::toHTML使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类HTML_Progress
的用法示例。
在下文中一共展示了HTML_Progress::toHTML方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
//-->
</script>
</head>
<body>
<table class="container">
<tr>
<td width="50%" align="center">
<?php
echo $bar1->toHTML();
?>
</td>
<td width="50%" align="center">
<?php
echo $bar2->toHTML();
?>
</td>
</tr>
</table>
<?php
do {
$bar1->display();
$bar2->display();
if ($bar2->getPercentComplete() == 1) {
break;
// the progress bar has reached 100%
}
if ($bar1->getPercentComplete() < 1) {
$bar1->process();
示例2: basename
<script type="text/javascript">
<!--
<?php
echo $bar->getScript();
?>
//-->
</script>
</head>
<body>
<h1><?php
echo basename(__FILE__);
?>
</h1>
<?php
echo $bar->toHTML();
$bar->run();
?>
<form>
Contents of file 'progress_observer.log' generated by HTML_Progress_Observer class
<textarea readOnly="true" rows="12" cols="80" wrap="virtual">
a:2:{s:3:"log";s:8:"incValue";s:5:"value";i:10;}
a:2:{s:3:"log";s:8:"incValue";s:5:"value";i:20;}
a:2:{s:3:"log";s:8:"incValue";s:5:"value";i:30;}
a:2:{s:3:"log";s:8:"incValue";s:5:"value";i:40;}
a:2:{s:3:"log";s:8:"incValue";s:5:"value";i:50;}
a:2:{s:3:"log";s:8:"incValue";s:5:"value";i:60;}
a:2:{s:3:"log";s:8:"incValue";s:5:"value";i:70;}
a:2:{s:3:"log";s:8:"incValue";s:5:"value";i:80;}
a:2:{s:3:"log";s:8:"incValue";s:5:"value";i:90;}