[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

re: [MacPerl] Re: MacPerl to Unix???



blisbarn@i-max.co.nz (Matt & Sheryl) write:
[snip]
} 
} what i needed to know was stuff concerning the actual file formats.  four
} of my scripts are saved as ".cgi" (using the MacPerl cgi glue) and the many
} others are just plain 'required' (".pl").
} i am very unsure as to whether using this glue for scripts to be used on a
} unix system will work.  i'm not too familiar with the technicalities of a
} cgi but based on the fact that (on a mac at least) a cgi is classed as an
} application program suggests that a unix server will not be able to execute
} it.
} 
} in a nutshell, do i need (and is there) a glue extension that can be used
} in order to save a script, written using macperl (on a mac, obviously),
} into a cgi that can be recognised and executed by a unix server?

No.  In fact, if I understand the way the glue works, you won't be able
to send the .cgi files to a Unix machine and have them work.  Send the
text only.

} 
} if there isn't can anyone suggest a solution apart from trading in my mac
} for a unix (god forbid anyone suggest it :-))?  would i need to send my cgi
} scripts, in plain text format, to the web bods of my future server and get
} them to convert them to unix cgi's?

That's all you have to do.  Make sure you send them something like ftp
text mode so the end-of-line conversion is done automatically.  Make
sure the scripts begin with #! followed by the path to the perl
executable on the Unix machine, for example #!/usr/local/bin/perl.  That
should be the very first line of the script.

Once it gets there, it's merely a matter of placing the file in a place
where the http server knows CGI's live.  You may or may not be able to
do this yourself.  Of course, I always think that an ISP would be crazy
to let Joe User put arbitrary CGI's on his machine, but I take it most
ISP's are crazy.


} 
} dazed and confused
} 
} matt
} 
} 
} ps. if i obviously appear a few slices short of a loaf then can someone
} also let me know :-)  cheers.
} 
} 
} 
---
--------
Paul J. Schinder
NASA Goddard Space Flight Center,
Code 693, Greenbelt, MD 20771 USA
schinder@pjstoaster.pg.md.us