in reply to CGI multipart_form not working
The problem is there is no output I can give, the page just refreshes itself, even in the logs files there is nothing to hold on, however now when I submit the form, the page hangs until I kill it. I don’t know what I did to the server!
The multipart_form stops the page with no output to operate on, but Im still trying to find something for you.
Running CGI script in Command line? I haven’t done it before, I’ll try
Also I tried the “application/x-www-form-urlencoded” which is the older version, but no luck
Ok the page is about 700 line of code, so I’ll show you the important bits:
And tell me of it’s not enough, I will send it all.
#--check of the form is submitted
if ($ENV{'REQUEST_METHOD'} eq "POST") {
#----set the limited size of the file(s) to be uploaded, the max file(s) size is 300 KB
our $limit = 300000;
#---retrieve the file(s) size from the client side:
our $content_length = defined $ENV{'CONTENT_LENGTH'} ? $ENV{'CONTENT_LENGTH'} : 0;
#--do some validation stuff if if if and store some data into the database à
}
#---start the form:
print $query->start_multipart_form(-method=>'post', -action=>'http://localhost/cgi-bin/cars/add_car.pl' );
#--car name fieldà
#--car model, color bla blaà
#--car picture:
print $query->filefield(-name=>'uploaded_file', -size=>70, -maxlength=>140), '
';
print p(reset, submit('submit', 'Submit'));
print $query->end_ multipart_form;
Thanks for your support dud.
I really need it.