hoopplaya4 Posted January 31, 2009 Share Posted January 31, 2009 Hi All, One more question: I've tried searching the web for a progress bar that displays the percentage of disk space available, however, all I can find is progress bars for "uploading." Do you know how I might either, a) create my own progress bar, or b) find one that's already been created? I currently have the percentage calculated, i.e. "You are using roughly 32% of your alloted disk space." However, I'd like to display this in a visual way as well. Thanks! Quote Link to comment Share on other sites More sharing options...
Snart Posted January 31, 2009 Share Posted January 31, 2009 http://www.phpclasses.org/browse/package/4987.html Not sure if it works properly. Quote Link to comment Share on other sites More sharing options...
thebadbad Posted January 31, 2009 Share Posted January 31, 2009 I would do it with simple XHTML and CSS. Example: <?php $percent = 32; echo '<div style="position: relative; display: block; width: 100px; height: 5px; border: 1px solid #888888; background-color: #eeeeee;"> <div style="position: absolute; top: 0; left: 0; z-index: 0; width: ', $percent, 'px; height: 5px; background-color: #888888;"></div> </div>'; ?> If you want it to be longer than 100 pixels, just manipulate $percent accordingly. Quote Link to comment Share on other sites More sharing options...
hoopplaya4 Posted January 31, 2009 Author Share Posted January 31, 2009 Thanks thebadbad, your method was very simple and exactly what I needed! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.