Gossamer Forum
Home : Products : DBMan : Customization :

Upload "Software" Error??

Quote Reply
Upload "Software" Error??
Carol,
Why is everything always so hard? I have gone through your mod and I have it running, well sort of...

The script works, except for the uploading part. I can get it and do everything else, but when I go to upload something, this big ugly error pops up.
---------------------------------------------
Software error:
CGI open of .\CGItemp1830001: Permission denied
For help, please send mail to this site's webmaster, giving this error message and the time and date of the error. ;
---------------------------------------------

eeerrrrrr YUCK!
I am the webmaster, so the buck stops with me. :-( :-(

Smile But alas, I have you. Smile (and your brain to pick)

So... do you have any thoughts? Could it be that my server does not have the CGI.pm module installed? It would figure if they didn't. They suck at everything else. I wanted to ask you first as I have be emailing them quite allot recently.

Or could it be that I stink at programming? Which is more likley the case... anyways, please help me AGAIN AND AGAIN AND AGAIN

Greg
Quote Reply
Re: Upload "Software" Error?? In reply to
I know the frustration. I feel your pain!! Smile

Did you set the permission for the file-upload.cgi file to 755? The "permission" error that you got makes me think that maybe you didn't.

If you did and it still is giving you problems, it could be that they don't have CGI.pm installed.

------------------
JPD





Quote Reply
Re: Upload "Software" Error?? In reply to
You can type in which CGI.pm at the command prompt in a telnet session to see if your server or account has access to the CGI.pm module.

If not, you can install it yourself by downloading the CGI.pm module from www.perl.com .

Regards,

------------------
Eliot Lee
Founder and Editor
Anthro TECH, L.L.C
http://www.anthrotech.com/
info@anthrotech.com
==========================
Coconino Community College
http://www.coco.cc.az.us/
Web Technology
Coordinator
elee@coco.cc.az.us
Quote Reply
Re: Upload "Software" Error?? In reply to
I run off of an NT server that does not have a Telnet Daemon. So there is no way for me to run anything at the command line. I have emailed "jose" asking him if they have cgi.pm installed, but I doubt that I will ever get a response.

I ran some short programs from the perl.com page that included cgi in them and they worked.
Here is one that worked:
---------------------------------------------
#!/usr/local/bin/perl

use CGI qw(:standard);

print header;
print start_html('A Simple Example'),
h1('A Simple Example'),
start_form,
"What's your name? ",textfield('name'),
p,
"What's the combination?",
p,
checkbox_group(-name=>'words',
-values=>['eenie','meenie','minie','moe'],
-defaults=>['eenie','minie']),
p,
"What's your favorite color? ",
popup_menu(-name=>'color',
-values=>['red','green','blue','chartreuse']),
p,
submit,
end_form,
hr;

if (param()) {
print
"Your name is",em(param('name')),
p,
"The keywords are: ",em(join(", ",param('words'))),
p,
"Your favorite color is ",em(param('color')),
hr;
}
print end_html;
---------------------------------------------

So, any other thoughts?
Quote Reply
Re: Upload "Software" Error?? In reply to
Did you reset the permission for the file?


------------------
JPD





Quote Reply
Re: Upload "Software" Error?? In reply to
 Smile THIS is SO STRANGE! Smile

It is uploading the files, (and it always has been) but the files do not have propper file names! The files lack the extension!

Remember when i was saying that I was getting a bunch of CGItemp373927 in my database directory, well those are the graphic files! (it took me a while to figure that out cus I was always using a text editor to open them...)

But they are not going to the right directory, and I am still getting an ERROR!!!!

if this is not confusing! I don't know what is... do you want to take a peek at the code?

is there any hope for me!!!
Quote Reply
Re: Upload "Software" Error?? In reply to
Here is what I have things set too:

$SAVE_DIRECTORY = "d:\\inetpub\\wwwroot\\heritageantiquemaps\\auction\\orders\\database\\auction\\orders\\database\\userupload";

# if (!(-d $SAVE_DIRECTORY)) {
# $message = "The directory you specified isn't really a directory.\nMake sure that this is indeed a directory and not a file.";
# }
Quote Reply
Re: Upload "Software" Error?? In reply to
Sorry for the spoof on the which command...I should've asked what operating system you were on.

Anyway, you do not have the directory set-up properly.

It should be:

Code:
d:/inetpub/wwwroot/heritageantiquemaps/auction/orders/database/auction/orders/database/userupload";

Also, try using the trailing slash after userupload and see what happens.

What are the permissions of the files and directories you have for the upload mod??

Make sure that the upload directory has READ, WRITE, and DELETE permissions for Everyone, IWAM/MACHINENAME, and IUSR/MACHINENAME. If you do not set up delete permissions, the files will never be deleted unless you manually delete them as the "Administrator" of your account.

Regards,

------------------
Eliot Lee
Founder and Editor
Anthro TECH, L.L.C
http://www.anthrotech.com/
info@anthrotech.com
==========================
Coconino Community College
http://www.coco.cc.az.us/
Web Technology
Coordinator
elee@coco.cc.az.us
Quote Reply
Re: Upload "Software" Error?? In reply to
Elliot, I am running my site on an server (I know, yuck), but that is what I am stuck with.

I am very sure that I have my permissions set correctly.

I have changed my $SAVE_DIRECTORY to match the one that you just typed in. And that works. In-fact, if I take out the line all together it still works. It also works with this
$SAVE_DIRECTORY ="Greg";
(Which uploads the file CGItemp1830001)
or this
$SAVE_DIRECTORY ="Elliot";
(Which uploads the file CGItemp1830002)
or this
$SAVE_DIRECTORY ="Carol";
(Which uploads the file CGItemp1830003)


But I still get this!!!
CGI ERROR
==========================================

Error Message : The directory isn't writable. Make sure that this directory is writable by all users.
At your UNIX command prompt, type chmod 777 /auction/orders/database

Quote Reply
Re: Upload "Software" Error?? In reply to
Hey, I'm Back! And with a new error! It seems that no matter what path I try, I get this error.

Right now I have it set too:

$SAVE_DIRECTORY = "auction/orders/database/userupload";


CGI ERROR
==========================================

Error Message : The directory you specified isn't really a directory.
Make sure that this is indeed a directory and not a file.



Quote Reply
Re: Upload "Software" Error?? In reply to
Is this the full path to the directory? Is it on the same server that the script is on? (These are two problems that other people have had.)

I just got my CGI.pm book and I'm working through the section on uploads. I may have something new for everyone soon. I hope! Smile


------------------
JPD





Quote Reply
Re: Upload "Software" Error?? In reply to
Carol,
I have tried several different paths, the one that works the "best" is
d:\\inetpub\\wwwroot\\heritageantiquemaps\\auction\\orders\\database\\userupload

When I use that path, I get this file dumped into my database directory "CGItemp1830006" or something similar...

The file contains this information:

GIF89a  vvvvfffUUUEEE111&r!!!`

but is otherwise useless.
Quote Reply
Re: Upload "Software" Error?? In reply to
Try changing the \\s to /s. (I keep forgetting about these non-Unix servers!)

Use

d:/inetpub/wwwroot/heritageantiquemaps/auction/orders/database/userupload

See if that does any better.


------------------
JPD





Quote Reply
Re: Upload "Software" Error?? In reply to
No luck JPDeni,
any other thoughts?
Quote Reply
Re: Upload "Software" Error?? In reply to
Not yet! Smile

I need to get finished answering questions on the forum and then I need to pick up my email. And then I can read my new book while I have some breakfast! Smile


------------------
JPD





Quote Reply
Re: Upload "Software" Error?? In reply to
don't give up on me now!!!!!!!!! This is so close to working!

Smile YOU CAN DO IT!!! Smile I KNOW YOU CAN Smile
Quote Reply
Re: Upload "Software" Error?? In reply to
Have a good breakfast Carol! (isn't it time for lunch???)

anyway, when you get a moment, could the problem be in...

$SAVE_DIRECTORY = param('SAVE_DIRECTORY');
chop $SAVE_DIRECTORY if ($SAVE_DIRECTORY =~ /\/$/);
Quote Reply
Re: Upload "Software" Error?? In reply to
Not time for lunch for me yet. I was up until after 3am, so I haven't been up long. Smile

You might try commenting out the lines

Code:
if (!(-d $SAVE_DIRECTORY)) {
$message = "The directory you specified isn't really a directory.\nMake sure that this is indeed a directory and not a file.";
}

Just put a # in the front of each of those lines. See what happens.


------------------
JPD





Quote Reply
Re: Upload "Software" Error?? In reply to
When you have the directory set to what Eliot showed you, is the file saved to that directory?



------------------
JPD





Quote Reply
Re: Upload "Software" Error?? In reply to
Map,

NT is not so bad...I maintain two NT servers at work, and also work on multiple UNIX virtual servers at home.

The problem is that the directory, /auction/orders/database, needs to be set in the following manner:

IUSR\MACHINENAME: Read, Write, Execute
IWAM\MACHINENAME: Read, Write, Execute
Everyone: Read and Write

The translation of these user accounts are the following:

IUSR\MACHINENAME = Owner
IWAM\MACHINENAME = Group
Everyone = Everyone

Also, make sure that you as the administrator have NOT taken ownership of that directory. If you have, then all set permissions are nullified, meaning that only you can add, delete, and edit files in that directory.

Hope this helps.

Regards,

------------------
Eliot Lee
Founder and Editor
Anthro TECH, L.L.C
http://www.anthrotech.com/
info@anthrotech.com
==========================
Coconino Community College
http://www.coco.cc.az.us/
Web Technology
Coordinator
elee@coco.cc.az.us