473,788 Members | 2,810 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ftp_put - How do I reference a file on my hard drive

I am just trying a simple up load of a file on my hard drive to my ftp
site.

$source_file="f ile://C:/1PRV.TXT";

I get the error "remote host file access not supported,
file://C:/1PRV.TXT"

I can connect, log on and change directories just fine.

Any help would be appreciated.

Thanks, Steve
Jul 17 '05 #1
4 3287
Try using "C:\\1PRV.T XT" as your local address?
se******@swbell .net wrote:
I am just trying a simple up load of a file on my hard drive to my ftp
site.

$source_file="f ile://C:/1PRV.TXT";

I get the error "remote host file access not supported,
file://C:/1PRV.TXT"

I can connect, log on and change directories just fine.

Any help would be appreciated.

Thanks, Steve

Jul 17 '05 #2
se******@swbell .net treated the lovely people of comp.lang.php
with the following stuff:
I am just trying a simple up load of a file on my hard drive to
my ftp site.

$source_file="f ile://C:/1PRV.TXT";

I get the error "remote host file access not supported,
file://C:/1PRV.TXT"

I can connect, log on and change directories just fine.

Any help would be appreciated.

Thanks, Steve


If the FTP functions are being used on a remote server then you
cannot reference files on your hard drive.

--
Phil Roberts | Deedle Doot Doo Dee Dee | http://www.flatnet.net/

I could be wrong here, You could be right
Please forgive me I have sinned - Not on your life
But that's how you want me, But I'll never fear thee
Why you and not me? Tell me Holy Man
Jul 17 '05 #3
Can this awful thing be true?

On Sat, 23 Oct 2004 17:31:28 -0500, Phil Roberts
<ph**********@g ooglemail.com> wrote:
se******@swbel l.net treated the lovely people of comp.lang.php
with the following stuff:
I am just trying a simple up load of a file on my hard drive to
my ftp site.

$source_file="f ile://C:/1PRV.TXT";

I get the error "remote host file access not supported,
file://C:/1PRV.TXT"

I can connect, log on and change directories just fine.

Any help would be appreciated.

Thanks, Steve


If the FTP functions are being used on a remote server then you
cannot reference files on your hard drive.

--
Phil Roberts | Deedle Doot Doo Dee Dee | http://www.flatnet.net/

I could be wrong here, You could be right
Please forgive me I have sinned - Not on your life
But that's how you want me, But I'll never fear thee
Why you and not me? Tell me Holy Man


Jul 17 '05 #4
se******@swbell .net wrote:
Can this awful thing be true?


Read this interesting article on web-based FTP with PHP:

http://www.raditha.com/php/ftp/

HTH
Markus
Jul 17 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
4677
by: balzano_1 | last post by:
Hi, im trying to upload a file from a client (windows) to an ftp server (linux), i deciede to use some of php`s functions to connect and authenticate etc.. i only wish to put a file on the server, so i used ftp_put() function, when i send the file via http, the file is created on the server, but it is empty, i checked the permissions and all are set correctly, i figured if it is empty it means it cant find the file im trying to upload, i...
5
6753
by: tripwater | last post by:
Hello, I am having problems with the ftp_put() function. I can login via shell prompt. Does anyone know why the ftp_put() function may not work? I went to the php site and followed the directions. I am connecting because I am not getting an error. I am also logging in with the username and password because I am not getting an error here as well. But so far no matter what I do, the file will not upload. Any help with this would be...
3
1690
by: J Poirier | last post by:
Hi All, I'm hoping that someone might have some pointers or examples on how to proceed with a solution to the following problem: A test application, which produces a trace file, is being run for very long periods of time. Say 72 hours or more.
1
2390
by: Daniel | last post by:
when writing out a file from .net, when is the file created? after the bytes are all written to the hard drive or before the bytes are written to the hard drive?
16
9533
by: Otie | last post by:
Hi, Is there a way for VB5 to determine exactly where on a hard drive a .exe file is stored upon the .exe file's first copying to the hard drive? What I need to know is the exact hard drive sector, cluster, partition, etc. information so I can use it later on to determine if the file was ever deleted and restored or moved elsewhere. Thank you.
3
21305
by: empiresolutions | last post by:
ftp_put() is not working. this is what i have. $host = "www.site.com"; $ftp_user_name = "username"; $ftp_user_pass = "password"; // declair files $remote_file = "ITS_BLI_0".$_POST.".csv"; // root level $file = "/upload/ITS_BLI_0".$_POST.".csv"; // this file dir is root/manager/posts/
3
1681
by: A_Republican | last post by:
I am interested in writing my own secure file deletion program. I want to be able to read and write to my hard drive directly. My application will seach my hard drive for all locations marked for deletion and then replace it with "x" or something that securely removes previoius data. My question is what objects, API calls, etc, etc do I use to read and write directly to the hard drive? -- Regards, Shaun Goldston
12
5600
by: benjamin.krulewitch | last post by:
I'm debugging an issue with a C program that causes the computer to crash, and I'm attempting to log information immediately before the crash occurs. I us my BKprintLog function (see below) to write information into a log file. The problem is, i'm not confident that information i write to the log gets saved onto the hard drive before the crash occurs. My understanding of hard drives and OS are that because hard drives are so slow,...
0
1689
by: sushil | last post by:
Hello Frnds, I am getting problem in uploading file from php script. The error is : Code - $upload = ftp_put($conn_id,$filemax,$src,FTP_BINARY); Output - Resource id #11,fairmont_mon.txt,/tmp/phpWmPlSJ Warning: ftp_put() : OOPS: vsf_sysutil_bind in /var/www/html/hview/hqc/twc_upload/upload_file.php on line 263
0
9656
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10172
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10110
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8993
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7517
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6750
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4069
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3670
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2894
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.