Problem

 
Post new topic   Reply to topic    Aprelium Forum Index -> Perl
View previous topic :: View next topic  
Author Message
Ambient
-


Joined: 16 Apr 2004
Posts: 15

PostPosted: Mon Sep 20, 2004 2:34 pm    Post subject: Problem Reply with quote

I'm new to perl, so i only just started with basic scripts form HTML and stuff.
my tutorial has moved me onto HTML forms, and stuff.
I do exactally as it says, and when i press the submit button, Instead of doing what it's supposed to. My browser trys to download it.... How do i make it run prop.

I've already installed perl into abyss.

Also, it dosen't read .cgi, it only reads .pl
If it's a .cgi i either get an error or it trys to download it....

How do i fix these problems, I really want to learn perl lol.

Code for get.pl
Code:

#!/perl/bin/perl -wT
use CGI qw(:standard);
use CGI::Carp qw(warningsToBrowser fatalsToBrowser);
use strict;

print header;
print start_html("Get Form");

my %form;
foreach my $p (param()) {
    $form{$p} = param($p);
    print "$p = $form{$p}<br>\n";
}
print end_html;

and

Code for HTML
Code:

<html><head><title>Test Form</title></head>
<body>

<form action="get.pl" method="GET"> 
First Name: <input type="text" name="firstname" size=30><br>
Last Name: <input type="text" name="lastname" size=30><br>
<input type="submit"><p>
</form>

</body></html>

_________________
Build Your Own Net Dream
Back to top View user's profile Send private message
Ambient
-


Joined: 16 Apr 2004
Posts: 15

PostPosted: Wed Sep 22, 2004 4:05 am    Post subject: Reply with quote

anybody?
_________________
Build Your Own Net Dream
Back to top View user's profile Send private message
Axis
-


Joined: 29 Sep 2003
Posts: 336

PostPosted: Wed Sep 22, 2004 4:16 am    Post subject: Reply with quote

Hello Ambient--

Have you correctly configured Abyss to run perl on your site? If you haven't already done so, please read some of the documentation on this site and in the help files that come with every Abyss installation.

Also, in asking this it is good if you can report what kind of error you are receiving. Do you have any perl scripts running successfully (to see if it is a basic configuration issue)?

Regards,
Axis
Back to top View user's profile Send private message
Ambient
-


Joined: 16 Apr 2004
Posts: 15

PostPosted: Wed Sep 22, 2004 11:10 am    Post subject: Reply with quote

I followed the "How do install Perl" thing.
And yes some basic scripts have run.
This is the first script that has given me this problem.
_________________
Build Your Own Net Dream
Back to top View user's profile Send private message
Axis
-


Joined: 29 Sep 2003
Posts: 336

PostPosted: Wed Sep 22, 2004 4:47 pm    Post subject: Reply with quote

Hello again Ambient--

You mentioned receiving errors. What errors were these? Also, what is being logged in your cgi error log (cgi.log) when trying to run the script?

Regards,
Axis
Back to top View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> Perl All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB phpBB Group