Progress bar, and changing text - LoadingURL

So, I come back once again with inquiries about creating a loading url.

Let’s cut to the chase:

1- How would I make it so it displays properly the downloading file, and actions it’s doing? (Note: I know how to display what’s going on the thing is, it’s writing it beside the previous text, instead of replacing it, n00b at Javascript here!)
2- How would I make a progress bar that displays the percentage of loading into the server, together with a nice graphic? (Do I calculate the amount of files that need to be downloaded, and the total, and make a percentage out of that, and then just add some values for the sending client, and such, or is there a proper way to do this?)


JavaScript is used. If you look up Gmod sv_loadingurl I think there is some information regarding how one would do this (i don’t remember the exposed JS functions off the top of my head)

For your progress bar look up JQueryUI as it has a nice set of widgets including a progress bar one that you can use. For calculating the progress simply devide how many have been downloaded so far by the total file count.