Oops... my problem: encoding attribute should be 'enctype' in my html form...
Thanks. Ken. -----Original Message----- From: Ken Burcham [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 07, 2004 10:28 AM To: [EMAIL PROTECTED] Subject: Question about file upload Hi guys, I'm trying to get file uploads to work and am just too ignorant of the process to troubleshoot what is going on. It seems like this should work but it doesn't. It is in an xsp file named "input": my $apr = Apache::Request->instance( $r ); my $upload = $apr->upload; if($upload) { my $filename = $upload->filename; warn "got an upload!: $filename"; }else{ warn "NO upload"; } # foreach my $upload ($r->upload) { ^M # my $filename = $upload->filename;^M # my $filehandle = $upload->fh;^M # my $size = $upload->size;^M # warn "UPLOAD A FILE FOUND!: $filename"; # } All I get is "NO upload" in the log. Here's the form html: <form action="/ken/tabletool/input" method="POST" encoding="multipart/form-data" name="uploadformtest" parent="uploadtest"> <input type="hidden" name="sys_name" value="uploadform"> <input type="hidden" name="sys_community" value="global"> <label for="filename">Filename</label> <input type="file" name="filename" value="" length="" max=""> <br><p class="button"> <input class="button" type="submit" name="sys_action" value="Upload" onClick=""> </form> Can I look for an example somewhere? Ken. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]