I received two responses to this, for which I am grateful, but neither
worked.
First, I replaced all of the "local" declarations with "my"
declarations. This removed all of the errors, but (as I thought it might)
it then kept those variables from being used in any subroutines. I need
these variables to be passed to subroutines, and returned. I suppose I
could just keep renaming variables as I pass them to subroutines, so that
everything can be defined with "my", but then what is the use of having a
"local" declaration available in the first place?
Second, I tried the solution below, but that did not remove the errors at all:
use LWP::Simple;
use CGI qw(:standard);
use Time::CTime;
use strict;
use vars qw(%labels,%nhllist,%nbalist,%nfllist,%mlblist,%regions);
use vars qw(@reglist,@nhllist,@nbalist,@nfllist,@mlblist);
use vars qw(@today,@tables,@r,@nhlteam,@nbateam,@mlbteam,@nflteam,@region);
use vars qw($R1,$R2,$R3,$R4,$R5);
use vars
qw($now,$oneday,$searchtype,$nhlteam,$nbateam,$nflteam,$mlbteam,$region);
I even tried "use strict qw(subs vars);" , but that did not work either.
Any other ideas? I am out of them.
Thanks, Jonathan
at12:11 PM 2/16/00 -0800, you wrote:
>use vars qw(%nhllist %nbalist %nfllist %mlblist %regions);
>
>cliff rayman
>genwax.com
>
>"J. Meltzer" wrote:
>
> > Global symbol "$nbateam" requires explicit package name at sports.cgi
> line 59.
> > Variable "$nbateam" is not imported at sports.cgi line 59.
> >
> >
> >
> > use LWP::Simple;
> > use CGI qw(:standard);
> > use Time::CTime;
> > use strict;
> >
> > require "./hashdata.pl";
> >
> > local (%nhllist,%nbalist,%nfllist,%mlblist,%regions) = {};
> > local (@reglist,@nhllist,@nbalist,@nfllist,@mlblist) = [];
> >
worked.
First, I replaced all of the "local" declarations with "my"
declarations. This removed all of the errors, but (as I thought it might)
it then kept those variables from being used in any subroutines. I need
these variables to be passed to subroutines, and returned. I suppose I
could just keep renaming variables as I pass them to subroutines, so that
everything can be defined with "my", but then what is the use of having a
"local" declaration available in the first place?
Second, I tried the solution below, but that did not remove the errors at all:
use LWP::Simple;
use CGI qw(:standard);
use Time::CTime;
use strict;
use vars qw(%labels,%nhllist,%nbalist,%nfllist,%mlblist,%regions);
use vars qw(@reglist,@nhllist,@nbalist,@nfllist,@mlblist);
use vars qw(@today,@tables,@r,@nhlteam,@nbateam,@mlbteam,@nflteam,@region);
use vars qw($R1,$R2,$R3,$R4,$R5);
use vars
qw($now,$oneday,$searchtype,$nhlteam,$nbateam,$nflteam,$mlbteam,$region);
I even tried "use strict qw(subs vars);" , but that did not work either.
Any other ideas? I am out of them.
Thanks, Jonathan
at12:11 PM 2/16/00 -0800, you wrote:
>use vars qw(%nhllist %nbalist %nfllist %mlblist %regions);
>
>cliff rayman
>genwax.com
>
>"J. Meltzer" wrote:
>
> > Global symbol "$nbateam" requires explicit package name at sports.cgi
> line 59.
> > Variable "$nbateam" is not imported at sports.cgi line 59.
> >
> >
> >
> > use LWP::Simple;
> > use CGI qw(:standard);
> > use Time::CTime;
> > use strict;
> >
> > require "./hashdata.pl";
> >
> > local (%nhllist,%nbalist,%nfllist,%mlblist,%regions) = {};
> > local (@reglist,@nhllist,@nbalist,@nfllist,@mlblist) = [];
> >