Go Back   CodingForums.com > :: Server side development > PHP

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 06-20-2006, 09:12 PM   PM User | #1
mint suite
New Coder

 
Join Date: Jun 2006
Posts: 62
Thanks: 2
Thanked 0 Times in 0 Posts
mint suite is an unknown quantity at this point
Ftp / php upload website

Could anyone give me some advise on this?

I need to build a facility for a client of mine to upload files for clients of theirs to download. Originally I was planning to do this in php (I've built a number of cms involving the uploads of files)but the size of the files may be an issue (they may be large files 10mb plus).

As well as allowing my client to upload I would also want my clients clients to upload too. I don't want to rely on everyone downloading an ftp programme.

Basically I would like uploads to be carried out via a browser.

What would be the best way for me to go about doing this? I know that I need to use ftp, but I could do with some help in where to start.
mint suite is offline   Reply With Quote
Old 06-20-2006, 09:25 PM   PM User | #2
lavinpj1
Regular Coder

 
Join Date: Sep 2005
Posts: 394
Thanks: 1
Thanked 0 Times in 0 Posts
lavinpj1 is an unknown quantity at this point
The only facility your web browser has for file uploading is posting. You will need to edit php.ini to upload larger files. You could also look at using java to upload the files, but I can't think of any good java clients.

~Phil~
lavinpj1 is offline   Reply With Quote
Old 06-20-2006, 09:39 PM   PM User | #3
mint suite
New Coder

 
Join Date: Jun 2006
Posts: 62
Thanks: 2
Thanked 0 Times in 0 Posts
mint suite is an unknown quantity at this point
Thanks for the help -

So.... if I alter the php.ini file I can upload large files with a php cms? Do I have to worry about the browser timing out?
mint suite is offline   Reply With Quote
Old 06-20-2006, 09:43 PM   PM User | #4
cubsfan
Regular Coder

 
Join Date: May 2006
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
cubsfan is an unknown quantity at this point
Might look at http://projects.adamsutton.co.uk/sum...k_project_id=3

I used it for a while in the past but have since stopped due to some issues with the ftp server I'm using.

Might also dig thru some of the links returned by http://www.google.com/search?hl=en&q...=Google+Search
cubsfan is offline   Reply With Quote
Old 06-20-2006, 09:45 PM   PM User | #5
lavinpj1
Regular Coder

 
Join Date: Sep 2005
Posts: 394
Thanks: 1
Thanked 0 Times in 0 Posts
lavinpj1 is an unknown quantity at this point
I don't see how you can use php as an ftp client. Maybe i'm wrong but...

PHP is a server side language, therefore the files must get to the server from your PC. The only way they can do that is by http post.

Correct me if i'm wrong

~Phil~
lavinpj1 is offline   Reply With Quote
Old 06-20-2006, 09:47 PM   PM User | #6
lavinpj1
Regular Coder

 
Join Date: Sep 2005
Posts: 394
Thanks: 1
Thanked 0 Times in 0 Posts
lavinpj1 is an unknown quantity at this point
Quote:
Thanks for the help -

So.... if I alter the php.ini file I can upload large files with a php cms? Do I have to worry about the browser timing out?
The browser won't time out. It is php that times out, and php only takes the file for processing after it has been uploaded.

~Phil~
lavinpj1 is offline   Reply With Quote
Old 06-20-2006, 09:49 PM   PM User | #7
cubsfan
Regular Coder

 
Join Date: May 2006
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
cubsfan is an unknown quantity at this point
There are built in ftp functions. http://us3.php.net/manual/en/ref.ftp.php. I primarily use the ftp functions for some php scripts I run as cron jobs. Should be able socket functions as well if you are so inclined. I've done that in the past for some basic NNTP functionality.

The upload from the browser to the server is by posting, but you can then FTP the file to an ftp server within the script.
cubsfan is offline   Reply With Quote
Old 06-20-2006, 10:34 PM   PM User | #8
mint suite
New Coder

 
Join Date: Jun 2006
Posts: 62
Thanks: 2
Thanked 0 Times in 0 Posts
mint suite is an unknown quantity at this point
ok - I've just downloaded Adam Suttons ftp php client as a zip but I can't open the read me or FAQ files. Cubsfan - is there any chance that you could give the gist of how this works?

Do I just upload it all to my server and build a page around the php file?

Sorry for sounding like an idiot.....
mint suite is offline   Reply With Quote
Old 06-20-2006, 10:53 PM   PM User | #9
mint suite
New Coder

 
Join Date: Jun 2006
Posts: 62
Thanks: 2
Thanked 0 Times in 0 Posts
mint suite is an unknown quantity at this point
forget that last post - got it working
mint suite is offline   Reply With Quote
Old 06-20-2006, 10:58 PM   PM User | #10
mint suite
New Coder

 
Join Date: Jun 2006
Posts: 62
Thanks: 2
Thanked 0 Times in 0 Posts
mint suite is an unknown quantity at this point
the read me and faq files would be good if they're handy. Cheers
mint suite is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 12:52 PM.


Advertisement
Log in to turn off these ads.