|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
uploading directories to FTP
I know how to upload files to FTP using PHP, but is there anyway to upload directories? Or at least empty directories of their content and upload it?
__________________
~ Kaen |
|
#2
|
||||
|
||||
|
If you're trying to emulate FTP using a HTML form through HTTP, no. The browse (<input type="file">) dialog only allows for a single file to be uploaded.
On the other hand, if you're using the FTP functions, you can script a function to browse from a given directory and get all the folders and included files, stuff them into an array, then ftp_mkdir/ftp_fput them to where ever you'd like. |
|
#3
|
|||
|
|||
|
For the FTP functions, can you explain to me how you would script a function to do that, please?
|
|
#4
|
||||
|
||||
|
Check the PHP manual online for the directory functions, then check devshed for tutorials on FTP functions in PHP. I'm sure there's some information there.
I got my directory-walking code from the PHP manual. |
![]() |
| Viewing: Dev Shed Forums > System Administration > FTP Help > uploading directories to FTP |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|