Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.php > #2758 > unrolled thread
| Started by | Norman Peelman <npeelman@cfl.rr.com> |
|---|---|
| First post | 2011-08-08 21:18 -0400 |
| Last post | 2011-08-16 19:12 -0400 |
| Articles | 6 — 4 participants |
Back to article view | Back to comp.lang.php
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: ftp with win-filenames with chr#32 ? Norman Peelman <npeelman@cfl.rr.com> - 2011-08-08 21:18 -0400
Re: ftp with win-filenames with chr#32 ? Jerry Stuckle <jstucklex@attglobal.net> - 2011-08-08 22:13 -0400
Re: ftp with win-filenames with chr#32 ? Norman Peelman <npeelman@cfl.rr.com> - 2011-08-09 06:23 -0400
Re: ftp with win-filenames with chr#32 ? Bjarne Jensen <bjarne.b.jensen@gmail.com> - 2011-08-09 12:53 +0200
Re: ftp with win-filenames with chr#32 ? Jo Schulze <antispam@feuersee.de> - 2011-08-17 00:05 +0200
Re: ftp with win-filenames with chr#32 ? Norman Peelman <npeelman@cfl.rr.com> - 2011-08-16 19:12 -0400
| From | Norman Peelman <npeelman@cfl.rr.com> |
|---|---|
| Date | 2011-08-08 21:18 -0400 |
| Subject | Re: ftp with win-filenames with chr#32 ? |
| Message-ID | <j1q1t5$db0$1@dont-email.me> |
On 08/08/2011 12:39 PM, Bjarne Jensen wrote:
> if (ftp_chdir($conn_id, "C:\Program Files")) {
> echo "REMOTE dir is now: " . ftp_pwd($conn_id) . "<br>";
> }
> else { echo "Couldn't change directory\n";
> }
>
>
> Warning: ftp_chdir() [function.ftp-chdir]: "C:\Program Files": Directory
> not found. in /var/www/ftp.php on line 20
> Couldn't change directory
>
> ---------
>
> How do you work around that?
> (yes, the dir is there)
>
> /Bjarne
Looks like you're mixing Windows paths with a linux/unix server...
but since it is possible to to have directories named like that, try:
ftp_chdir($conn_id, "C\:\\Program\ Files/");
You need to escape the ':' and spaces... and check the permissions.
--
Norman
Registered Linux user #461062
-Have you been to www.php.net yet?-
[toc] | [next] | [standalone]
| From | Jerry Stuckle <jstucklex@attglobal.net> |
|---|---|
| Date | 2011-08-08 22:13 -0400 |
| Message-ID | <j1q559$tak$1@dont-email.me> |
| In reply to | #2758 |
On 8/8/2011 9:18 PM, Norman Peelman wrote:
> On 08/08/2011 12:39 PM, Bjarne Jensen wrote:
>> if (ftp_chdir($conn_id, "C:\Program Files")) {
>> echo "REMOTE dir is now: " . ftp_pwd($conn_id) . "<br>";
>> }
>> else { echo "Couldn't change directory\n";
>> }
>>
>>
>> Warning: ftp_chdir() [function.ftp-chdir]: "C:\Program Files": Directory
>> not found. in /var/www/ftp.php on line 20
>> Couldn't change directory
>>
>> ---------
>>
>> How do you work around that?
>> (yes, the dir is there)
>>
>> /Bjarne
>
> Looks like you're mixing Windows paths with a linux/unix server... but
> since it is possible to to have directories named like that, try:
>
> ftp_chdir($conn_id, "C\:\\Program\ Files/");
>
> You need to escape the ':' and spaces... and check the permissions.
>
Neither colons nor spaces need to be escaped. In fact, "\:" and "\ "
are illegal escape sequences.
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================
[toc] | [prev] | [next] | [standalone]
| From | Norman Peelman <npeelman@cfl.rr.com> |
|---|---|
| Date | 2011-08-09 06:23 -0400 |
| Message-ID | <j1r1qs$duc$1@dont-email.me> |
| In reply to | #2759 |
On 08/08/2011 10:13 PM, Jerry Stuckle wrote:
> On 8/8/2011 9:18 PM, Norman Peelman wrote:
>> On 08/08/2011 12:39 PM, Bjarne Jensen wrote:
>>> if (ftp_chdir($conn_id, "C:\Program Files")) {
>>> echo "REMOTE dir is now: " . ftp_pwd($conn_id) . "<br>";
>>> }
>>> else { echo "Couldn't change directory\n";
>>> }
>>>
>>>
>>> Warning: ftp_chdir() [function.ftp-chdir]: "C:\Program Files": Directory
>>> not found. in /var/www/ftp.php on line 20
>>> Couldn't change directory
>>>
>>> ---------
>>>
>>> How do you work around that?
>>> (yes, the dir is there)
>>>
>>> /Bjarne
>>
>> Looks like you're mixing Windows paths with a linux/unix server... but
>> since it is possible to to have directories named like that, try:
>>
>> ftp_chdir($conn_id, "C\:\\Program\ Files/");
>>
>> You need to escape the ':' and spaces... and check the permissions.
>>
>
> Neither colons nor spaces need to be escaped. In fact, "\:" and "\ " are
> illegal escape sequences.
>
Ahh, was looking at terminal usage thinking it was the same... (now
i'm mixing bash and servers). I'd still like to see the directory
structure. Looks like something to keep a script from breaking.
--
Norman
Registered Linux user #461062
-Have you been to www.php.net yet?-
[toc] | [prev] | [next] | [standalone]
| From | Bjarne Jensen <bjarne.b.jensen@gmail.com> |
|---|---|
| Date | 2011-08-09 12:53 +0200 |
| Message-ID | <4e4111c2$0$302$14726298@news.sunsite.dk> |
| In reply to | #2758 |
On 2011-08-09 03:18, Norman Peelman wrote: > Looks like you're mixing Windows paths with a linux/unix server... but > since it is possible to to have directories named like that, try: Yes, should have written that I'm trying to access a win server fom a linux box. Tks!
[toc] | [prev] | [next] | [standalone]
| From | Jo Schulze <antispam@feuersee.de> |
|---|---|
| Date | 2011-08-17 00:05 +0200 |
| Message-ID | <4e4ae9be$0$6579$9b4e6d93@newsspool3.arcor-online.net> |
| In reply to | #2758 |
Norman Peelman wrote: > You need to escape the ':' Nope
[toc] | [prev] | [next] | [standalone]
| From | Norman Peelman <npeelman@cfl.rr.com> |
|---|---|
| Date | 2011-08-16 19:12 -0400 |
| Message-ID | <j2etgp$qlj$1@dont-email.me> |
| In reply to | #2857 |
On 08/16/2011 06:05 PM, Jo Schulze wrote: > Norman Peelman wrote: > >> You need to escape the ':' > > Nope Uh, yeah... we came to that conclusion last week. Thanks though. -- Norman Registered Linux user #461062 -Have you been to www.php.net yet?-
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.php
csiph-web