I am trying to use the perl module CGI::ProgressBar
When I use the example code from the cpan page I dont see a progress bar on my browser. The page just seems to hang for the duration of the test then displays the final page.
I am pretty sure I have the prereqs in terms of javascript enabled on browser etc. Any help would be greatly appreciated
Code I am using is
use strict;
use warnings;
use CGI::ProgressBar qw/:standard/;
$| = 1; # Do not buffer output
print header,
start_html(
-title=>'A Simple Example',
-style=>{
-src => '', # You can override the bar style
+here
-code => '', # or inline, here.
}
),
h1('A Simple Example'),
p('This example will update a JS/CSS progress bar.'),
progress_bar( -from=>1, -to=>100 );
# We're set to go.
for (1..10){
print update_progress_bar;
# Simulate being busy:
sleep 1;
}
# Now we're done, get rid of the bar:
print hide_progress_bar;
print p('All done.');
print end_html;
exit;
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.
|