Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- set_time_limit(600);
- error_reporting(E_ALL);
- ini_set('display_errors', TRUE);
- ini_set('display_startup_errors', TRUE);
- isset($_REQUEST["limit"]) ? $limit = $_REQUEST["limit"] : $limit = 15;
- isset($_REQUEST["longorshort"]) ? $longorshort = $_REQUEST["longorshort"] : $longorshort = "long";
- $start = 1;
- echo '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
- <html>
- <head>
- <meta http-equiv="content-type" content="text/html; charset=iso-8859-1">';
- echo "<title>Test Script 2</title></head><body>";
- echo '<script src="test_script_js7.js"></script>';
- echo "
- <br>Clicking the button below will start the script running
- <br>The script called via XMLHttpRequest will generate a random delay between 40 and 55 seconds (5-10 seconds if \"longorshort\" is set to \"short\" in the url string), then a randomly generated string will be displayed in the table on the bottom
- <br>The default limit on iterations is fifteen
- <br>When the process terminates normally, the phrase \"test complete\" will be output in the \"Main Info\" cell
- <br><b>The script called via XMLHttpRequest will <u>never take more than 60 seconds</u> to complete processing</b>
- ";
- echo "<br><img src=start.jpg onclick=\"getter_outer($limit, '$start', '$longorshort')\"><br><a href=\"javascript:master_switch();\">click here to abort</a> ";
- echo "<table border=1><tr>";
- echo "<td valign=top><div id=main_info>Main Info:</div></td>";
- echo "<td valign=top><div id=iteration>Iterations:</div></td>";
- echo "<td valign=top><div id=message>Messages:</div></td>";
- echo "</tr></table>";
- echo "<table border=1 style=table-layout:fixed;><tr>";
- for ($i = 1; $i <= $limit; $i++) {
- echo "<td valign=top><div class=getter id=post_$i><i>Result $i</i></div></td>";
- if ( ($i%5 == 0) ) {echo "</tr><tr>";}
- }
- echo "</tr></table>";
- echo '</body></html>';
- ?>
Advertisement
Add Comment
Please, Sign In to add comment