Jump to content

thor erik

New Members
  • Posts

    5
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

thor erik's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. [quote author=micah1701 link=topic=102873.msg408940#msg408940 date=1154619778] well you might want to check out the usleep() function @ http://www.php.net/usleep but I think it might not help. I'm not sure what your trying to do, but your logic might be flawed. If you want it to display an image while the script executes - it won't work - because PHP runs server side and the script finishes running BEFORE it exports to the browser. which means if you echo an image and then have PHP do stuff -- the image wont display until the entire script finishes running. your alternative would be to either use AJAX - load the image then, call the script to load on another page in the background and replace the image w/ its results - this can be done with javascipt (google AJAX) or, use two pages. the first one has the image load then a meta tag or something forwards to the page w/ the script.  the first page will hang, displaying the image, for as long as it takes the second page to finish processing.  then it will load the second page [/quote] kk can you give me an code example of the last version?
  2. Well i'm going to try out an idea i had. but i got this problem that the script is done loading before the test image is done. how can i make the script continue running until the image is loaded? the scrip: [code]<?php $file = "waiting.jpg"; $size = filesize($file); $timer = microtime(); $size = filesize($file); $bits = $size*"9"; $kbits = $bits/'1000'; $kbps = $kbits/$timer; echo '<img src="waiting.jpg" />'; // test image. 3.22 mb large echo "<br />"; echo $kbps; ?>[/code]
  3. the thing is that i want it to automaticly to meassure your bandwidth.
  4. well my scrip is automaticly calculating the ammoun of time. but instead of [code]$values = array("DSL(high speed)"=>2048,     "DSL(medium speed)"=>1024, "DSL(low speed)"=>768,                     "ISDN"=>128,                     "Modem"=>56.6                       );[/code] i want one value witch is the persions band width i got an idea of how it can be done but i dunno if it will work nor how to do it.
  5. Well i'm working on a script that makes an approximation of the time it will take to download a file. but i need some sort of a measurement. i've tried varius ways but atm it returns with faulty speeds :/ can any one help me?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.