You are viewing a plain text version of this content. The canonical link for it is here.
Posted to embperl@perl.apache.org by Kevin Drew <ke...@stonehill.com.au> on 2002/07/23 19:03:11 UTC

newbie

I am not sure if I am emailing to the correct list, but I have been struggling with this for about 3 days and wondered if anyone could help me.

I have been put in charge of trying to get the file upload command to work with out Apache server on OSX.  I have found this page.

http://perl.apache.org/docs/1.0/guide/snippets.html#File_Upload_with_Apache__Request

It says to  put a function called "form()" (which is listed on the page) into the perl mod_handler.  I am not really sure what they mean by this.

I found a directory called 

/System/Library/Perl/darwin/auto/mod_perl

but there was nothing in it.  Should I just create a file and put this function into it?  What do I call it?

is the code above C code? 

I think what I have to do it is compile Apache with this code added somewhere.

Re: newbie

Posted by Gavin Carr <ga...@openfusion.com.au>.
Hi Kevin,

There are multiple ways of doing this, depending on what framework you're
planning to use. For instance, the CGI module, mod_perl, and embperl
(HTML::Embperl - this mailing list) all allow you to do file uploads
pretty easily - your snippet is for a mod_perl solution (in perl).

If you're not already using embedded perl or mod_perl, you might be best
exploring the CGI module (try 'perldoc CGI' and search for UPLOAD), if 
it's on your OSX box. If not, you can install it by downloading from
CPAN (e.g. http://planetmirror.com/pub/cpan/modules/by-module/CGI/, in
Australia), unpacking it somewhere, and doing

  perl Makefile.PL
  make
  make test
  make install

Hope that helps.

Cheers,
Gavin

On Tue, Jul 23, 2002 at 06:03:11PM +0100, Kevin Drew wrote:
> I am not sure if I am emailing to the correct list, but I have been
> struggling with this for about 3 days and wondered if anyone could
> help me.
> 
> I have been put in charge of trying to get the file upload command to
> work with out Apache server on OSX.  I have found this page.
> 
> http://perl.apache.org/docs/1.0/guide/snippets.html#File_Upload_with_Apache__Request
> 
> It says to  put a function called "form()" (which is listed on the
> page) into the perl mod_handler.  I am not really sure what they mean
> by this.
> 
> I found a directory called 
> 
> /System/Library/Perl/darwin/auto/mod_perl
> 
> but there was nothing in it.  Should I just create a file and put this
> function into it?  What do I call it?
> 
> is the code above C code? 
> 
> I think what I have to do it is compile Apache with this code added
> somewhere.

-- 
Fashion is a variable, but style is a constant - Programming Perl

---------------------------------------------------------------------
To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
For additional commands, e-mail: embperl-help@perl.apache.org