From: Perl Perl [mailto:perl.solut...@gmail.com] 
Sent: 17 March 2009 16:49
To: Brian Raven
Cc: perl-win32-users@listserv.activestate.com
Subject: Re: Perl Login Script using CGI module


> Hi Brian, 
>         Thanks a lot for your kind mail and in detail description.
> Please find the the code I have written as per your suggestion, but
while running I got the error which is 
> pasted after code.
> 
> #!/usr/bin/perl -w
> use CGI ':standard';
> 
> use CGI::Carp qw{fatalsToBrowser};
> 
> $q = new CGI;
> print $q->header(),
> $q->start_html(-title=>'Login Window!'),
>       $q->h1('Login Window!'),
> 
> print $q->start_form();
> print textfield(-name=>'field_name',
>                     -value=>'starting value',
>                     -size=>50,
>                     -maxlength=>80);
> 
> 
> print password_field(-name=>'secret',
>                                 -value=>'starting value',
>                                 -size=>50,
>                                 -maxlength=>80);
> 
> print submit();
> print $q->end_form();
> print $q->end_html;
> 
> 
> Error message as below.
>  
> Internal Server Error
> The server encountered an internal error or misconfiguration and was
unable to complete your request.
> Please contact the server administrator, webmas...@company.com and
inform them of the time the error occurred, > and anything you might
have done that may have caused the error.
> 
> More information about this error may be available in the server error
log.
> 
> P.S: I agree that i didn't used the strict here. 

You really should have "use strict;" in your scripts, and "use
warnings;" is generally preferable to the -w switch. It will help you
find bugs in your code.

Also, it would be better to use CGI consistently, and not mix OO and
non-OO calls.

Your problem is likely to be with your web server (have you checked its
error log?). Is it configured to run CGI programs, and from the
directory that you are running them from? 

HTH

-- 
Brian Raven 

-----------------------------------------------------------------------------------------------------------
This e-mail may contain confidential and/or privileged information. If you are 
not the intended recipient or have received this e-mail in error, please advise 
the sender immediately by reply e-mail and delete this message and any 
attachments without retaining a copy. Any unauthorised copying, disclosure or 
distribution of the material in this e-mail is strictly forbidden.


_______________________________________________
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to