<?xml version="1.0" encoding="windows-1252"?>
<node id="1020697" title="CGI::ProgressBar Module Help Required" created="2013-02-26 09:13:16" updated="2013-02-26 09:13:16">
<type id="115">
perlquestion</type>
<author id="1020665">
slb985</author>
<data>
<field name="doctext">
&lt;p&gt;I am trying to use the perl module CGI::ProgressBar&lt;/p&gt;

&lt;p&gt;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.&lt;/p&gt;

&lt;p&gt;I am pretty sure I have the prereqs in terms of javascript enabled on browser etc. Any help would be greatly appreciated&lt;/p&gt;

&lt;p&gt;Code I am using is &lt;/p&gt;

&lt;code&gt;        use strict;
        use warnings;
        use CGI::ProgressBar qw/:standard/;
        $| = 1; # Do not buffer output
        print header,
                start_html(
                        -title=&gt;'A Simple Example',
                        -style=&gt;{
                        -src  =&gt; '', # You can override the bar style here
                        -code =&gt; '', # or inline, here.
                        }
                ),
                h1('A Simple Example'),
                p('This example will update a JS/CSS progress bar.'),
                progress_bar( -from=&gt;1, -to=&gt;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;
&lt;/code&gt;
</field>
</data>
</node>
