Jump to content

Bandwidth Help...


steviez

Recommended Posts

You will not get the precise bandwidth usage for a file if all you do is multiply the times downloaded by the size of the file. This does not take into account the people who canceled the download. If you don't know PHP, you could always look into server logs, possibly even download another free software program that could parse out that information for you.

Link to comment
Share on other sites

You will not get the precise bandwidth usage for a file if all you do is multiply the times downloaded by the size of the file. This does not take into account the people who canceled the download. If you don't know PHP, you could always look into server logs, possibly even download another free software program that could parse out that information for you.

 

That is true, but it will give an estimate of usage, which will be shot high. I would rather have a higher estimate than a lower.

Link to comment
Share on other sites

What i want to do is tell each user how much BW they have used, then if possable have like a percentage bar?

 

Is this very hard to do?

 

Anything worth doing is hard to do. I am sure you can find something already done on google.

Link to comment
Share on other sites

The percentage bar can easily be done in CSS or with www.php.net/image functions using www.php.net/gd the GD2 Library.

 

The bandwidth per user is pretty easy to calculate you just pull the download logs for each user and tally up the bytes for the file for the number of times they downloaded it.

 

http://www.codewalkers.com/c/a/File-Manipulation-Code/Bandwidth-Control-with-pure-PHP/

 

 

Link to comment
Share on other sites

@ steviez - I'd say you now have everything you need to begin coding the script you want.  When you have some code, please post it and identify any problems you're having with it.  Remember this is free help - members helping you, not members writing scripts for you.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.