Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 519
  • Last Modified:

PHP Windows - Client upload to ftp account

Hi,
  I have a client who wants to allow visitors to upload files to their website but want the files to end up on
a different server (ie the website could be www.mydomain.com and they want the files to end up on server 76.76.76.75). They have provided us with the ftp login for the server where they want the files to end up. What would be the best way to accomplish this? I know php is capable of doing ftp but is there an easier way to accomplish this?

Thanks
0
Goldblum
Asked:
Goldblum
  • 3
  • 3
  • 2
1 Solution
 
Jonah11Commented:
I'd recommend a Java applet.  This one is very easy to configure and use:

http://jumploader.com/
0
 
GoldblumAuthor Commented:
Hi Jonah11,
       Thanks, that looks good. If I am reading it correctly, it needs a php page on the server where the files go? Am I misreading that or is that correct?

Thanks
0
 
Jonah11Commented:
It needs a regular old html page on the server where the clients are browsing.  The most bare bones would look like the code below.  The server where the files get sent to does not need anything, except its FTP set up.


<applet name="jumpLoaderApplet"
		code="jmaster.jumploader.app.JumpLoaderApplet.class"
		archive="jumploader_z.jar,ftp_z.jar"
		width="600"
		height="400" 
		mayscript>
	<param name="uc_uploadUrl" value="ftp://public_ftp_username:public_password@76.76.76.75"/>
</applet>

Open in new window

0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
Jonah11Commented:
I should note I have only used this personally where the ftp server and the html server were the same, but I see no reason it would not work with the setup you want.
0
 
mattibuttCommented:
You can certianly use php ftp classes but you can also use a non php soloution by uploading files to temp folder and use some tool to upload file from the backend automatically
0
 
GoldblumAuthor Commented:
Hi Mattibutt,
             I had considered that but ideally I wanted something simpler and not requiring from point a to point b to point c as there are too many chances of failure.

Jonah11: I set up a page to test out the jumploader and it failed but it also failed when I tried to upload through the ftp command line tool. I suspect this will be the way we go. As soon as I confirm it works I will accept your solution.

Thanks
0
 
mattibuttCommented:
You also have to consider bandwidth if server is on share or slow connections it wqill jalt the site
0
 
GoldblumAuthor Commented:
Thanks. Once the ftp server problem was resolved this was quite easy to get going.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

  • 3
  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now