XUpload - Windows Server

Message
Author
Usagi
Posts: 5
Joined: Aug 28, 2006 1:59 pm

Windows Server

#1 Postby Usagi » Aug 28, 2006 6:13 pm

I've installed this on a Windows XP Server
Apache 2.0.55
Perl 5.6.1 (ActiveState)

I can only get "Transfer Complete" and then there is no uploaded file in /upload.

I can see a folder named with a number containing a file like "CGItemp16013" in the /temp after an upload.

Another question: Can an upload be resumed if the connection is lost?

Usagi

admin
Site Admin
Posts: 1839
Joined: Mar 22, 2006 12:32 pm

Re: Windows Server

#2 Postby admin » Aug 29, 2006 8:35 am

Usagi wrote:I've installed this on a Windows XP Server
Apache 2.0.55
Perl 5.6.1 (ActiveState)

I can only get "Transfer Complete" and then there is no uploaded file in /upload.

I can see a folder named with a number containing a file like "CGItemp16013" in the /temp after an upload.

Another question: Can an upload be resumed if the connection is lost?

Usagi

Do you see uploading progress bar while uploading?

Usagi
Posts: 5
Joined: Aug 28, 2006 1:59 pm

#3 Postby Usagi » Aug 29, 2006 8:33 pm

The popup appears but is completely white for a few seconds then "Transfer Complete" appears.

I changed the location of the perl in the two cgi files and obviously perl is working or the popup would not appear or it would have an error screen.

There are the relevent lines in XUploadConfig.pm:
# Directory for temporary using files
temp_dir => 'C:\\Server\\mysite\\cgi-bin\\xupload\\temp',

# Directory for uploaded files
target_dir => 'C:\\Server\\mysite\\cgi-bin\\xupload\\uploads',

# Path to the template using for upload status window
templates_dir => 'C:\\Server\\mysite\\cgi-bin\\xupload\\Templates',

# Allowed file extensions delimited with '|'
ext_allowed => 'jpg|jpeg|gif|png|rar|zip|mp3|avi|txt|csv',

# The link to redirect after complete upload
# This setting can be submitted from HTML form, then it will have priority
redirect_link => 'http://www.mysite.com/upload/upload.php',


I changed the name and location of upload_file.html to /upload/upload.php
Here are exact copies of the lines I changed in that file :

win1 = window.open('http://www.mysite.com/cgi-bin/xupload/u ... esizable=1');

<form name="F1" enctype="multipart/form-data" action="http://www.mysite.com/cgi-bin/xupload/u ... upload_id=" method="post" onSubmit="return StartUpload();" target="upload">

thanks

Usagi

User avatar
PilgrimX182
Posts: 2186
Joined: Mar 22, 2006 1:39 pm

#4 Postby PilgrimX182 » Aug 30, 2006 5:02 pm

1) Change double '\' in pathes to single: e.g. 'C:\Server\mysite\cgi-bin\xupload\temp'

2) in upload.cgi find this string:

Code: Select all

rename($temp,"$dir/$fname");
change it to

Code: Select all

move($temp,"$dir/$fname") || copy($temp,"$dir/$fname") || die"Can't copy file from temp dir";
Also add

Code: Select all

use File::Copy;
to the top of upload.cgi

3) I think You have "Transfer Complete" cause uploading files are too small. Try this: in upload.cgi find

Code: Select all

select(undef, undef, undef,0.1);
change it to

Code: Select all

sleep 3;
4) If nothing happens or you want much stable version, try XUpload Pro

Usagi
Posts: 5
Joined: Aug 28, 2006 1:59 pm

#5 Postby Usagi » Aug 30, 2006 8:53 pm

With these changes this happens:

The uploading popup appears but it contains nothing. After about 10 seconds the uploading bar and text appear. By that time about 7 megs have already been uploaded so the progress bar is useless for any files under 7 megs in size.

When uploading a larger file (255 megs) it goes to 99% hesitates there for about 10 seconds then reports "Upload Failed". However when I look at the failed upload it is there and functions (a zip file and it opens the zipped files)

The temp files are still there and are never erased.

As for buying the Pro version, I believe the bugs need to be fixed in the free version before one tries to sell a Pro version. It does not seem like a good idea to pay for a pro version when there are bugs in the free version which cannot be solved.

Usagi

User avatar
PilgrimX182
Posts: 2186
Joined: Mar 22, 2006 1:39 pm

#6 Postby PilgrimX182 » Aug 31, 2006 5:44 am

The uploading popup appears but it contains nothing. After about 10 seconds the uploading bar and text appear. By that time about 7 megs have already been uploaded so the progress bar is useless for any files under 7 megs in size.
Are you running server on local computer? Probably self-to-self uploading take too much resources(in my tests speed was about 10Mb/s) and slow down progress bar updating. Try it from another computer or over proxy using slower connection speed.

When uploading a larger file (255 megs) it goes to 99% hesitates there for about 10 seconds then reports "Upload Failed". However when I look at the failed upload it is there and functions (a zip file and it opens the zipped files)
I believe this happens cause file copying take too much time since huge filesize. In linux version we just move file, so this takes a moment, but Windows lock it and we have to copy. I will fix wrong "Failed" message asap.

The temp files are still there and are never erased.

As for buying the Pro version, I believe the bugs need to be fixed in the free version before one tries to sell a Pro version. It does not seem like a good idea to pay for a pro version when there are bugs in the free version which cannot be solved.
Correct temp files cleanup was implemented in Pro version some months ago. Will patch the Free version tonight, it looks a bit outated.