Re: \-decoding filename parameters [general issue now #270]

On 4 Feb 2011, at 11:13, Julian Reschke wrote:
> On 04.02.2011 11:40, Ben Niven-Jenkins wrote:
>> http://greenbytes.de/tech/tc2231/#attabspathwin
>> 
>> Firefox =>  \foo.html
>> Chrome =>  \\foo.html
>> Safari =>  \\foo.html
> 
> But this is not; apparently those UAs consider "\" a legitimate character in a filename.
> 
> I believe that's a very bad idea.

The handling of file names with a "\" in on Mac OS X is somewhat erratic.

You can save a file from a "GUI" application with \ in the fileanme, and at least some applications will open them (I only tried with TextEdit and MS Word) but while you can see them with an ls in a shell you get a "no such file/directory" error if you try access one. If you create a file with a \ in the filename from the shell the \ gets stripped out.

Firefox has some inconsistent behaviour - it won't open a file that starts with a \ and just presents a blank page but will open a file with a filename of the form foo\bar

I didn't try any other browsers.

Ben

Received on Friday, 4 February 2011 11:47:13 UTC