[Melbourne-pm] Wierd CGI Error - different displays for different executers

Sam Brent sambrent at gmail.com
Thu Mar 23 22:57:56 PST 2006

Hi, thanks everyone for getting back to me.

I'm not reading from a file exactly, I'm using LWP to get data from a
webpage then reinterpreting that data and printing it on my webpage. 
I don't think it's a permission problem, i've given chmod 777 to
everything including the folder my script is running in and it's still
doing the same thing.

I think that's what you meant, I'm still learning UNIX so I may be wrong...

If anyone else has any ideas I'd love to hear them.


P.S. It also wasnt an issue of filestructure, since i'm using just
this script, a pm in the same folder and LWP. ta.

On 3/23/06, Jacinta Richardson <jarich at perltraining.com.au> wrote:
> Sam Brent wrote:
> > Has anyone ever had a CGI script that creates the right output when
> > run in a terminal but the incorrect ouput when run in a browser?
> >
> > With a script I'm running, all the hard coded prints are carrying
> > through fine, i.e:
> >
> > print header, start_html() etc. etc.
> >
> > but prints that actually use perl to get their parameters like reading
> > from a file then printing the output go nowhere.
> >
> > Any thoughts?
> Unfortunately you're not really giving enough information for me to
> properly understand what symptoms you're seeing.  If you can show us the
> code for some of these weird prints, I might have a better idea.
> The common problems for differences between CGI scripts run on the
> command line vs those run via a web server are permissions.  If you're
> trying to read from a file and print that data, you should check that
> the open succeeded.  The web server may not have the same user id as
> yourself.
> All the best,
>      Jacinta

Samuel James Brent
MSN: sammyleephd at hotmail.com
Mobile: 0419201806

More information about the Melbourne-pm mailing list