Results 1 to 9 of 9

Thread: Perl......

  1. #1

    Thread Starter
    New Member
    Join Date
    Nov 2001
    Location
    Arlington,TX
    Posts
    10

    Question Perl......

    when i open the script...it ALWAYS shows the script in the page .. why?!?! im just beginning in perl....thanx...
    .....

  2. #2
    Hyperactive Member progressive's Avatar
    Join Date
    Sep 2001
    Location
    Manchester, UK
    Posts
    404
    Are you runnin a webserver? If not then u need to be!

    If you have a webserver then you need to make sure that:
    you have a cgi-bin,
    the cgi-bin is setup for perl scripts,
    and the script is in the cgi-bin

    if all of the above is done and it still doesn't work then post your code and ill take look at it for u



  3. #3
    scoutt
    Guest
    you will also need the shebang line.

    that is the line that is at the very top and looks somehting like this.

    #!usr/bin/perl

    that tells the browser where perl is located on the server.

    also do like progressive says, your server has to support cgi.

  4. #4
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    Do you still need the shebang line under mod_perl? Since its not running under CGI, I don't see why you would need to tell the shell where the executable is, unless Apache uses it internally, maybe for the switches.
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  5. #5
    Hyperactive Member progressive's Avatar
    Join Date
    Sep 2001
    Location
    Manchester, UK
    Posts
    404
    yes you still need it!!

  6. #6
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    What purpose does it serve then?
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  7. #7
    scoutt
    Guest
    Originally posted by JoshT
    What purpose does it serve then?
    you had it right the first time, it tells apache where perl is.

  8. #8
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    But by using mod_perl, shouldn't apache have that loaded into memory and using that instead - rather than the executable like you would with cgi?
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  9. #9
    Fanatic Member
    Join Date
    Aug 2001
    Posts
    746
    on apache it comes with a demo cgi script in perl. when i goto the address it says there was a internal server error. why?
    FlameWave Technologies - internet tools

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width