Re: Handling Macintosh filenames in PHP
| From: | Brian S. Dunworth | Date: | Fri, 20 Apr 2001 18:17:29 +0000 |
| Subject: | Re: Handling Macintosh filenames in PHP | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-49592@lists.php.net to get a copy of this message | ||
At 09:52 PM 4/19/01 -0400, Shawn Reed <shawn@remotebackupcenter.com> wrote:
However, it occurred to me that there isn't really a way (that I know of) to directly address a specific filename on a Macintosh as there is in other operating systems. For example, in Windows I could type C:\WINDOWS\SYSTEM\BLAH.EXE or in Unix I could type /var/spool/mail/whatever ... but is there a way to do such a thing on a Mac?Not recommended (you *should* use the ToolBox routines and create an 'alias' resource for the file), but yes, you can do what you're trying to do. "Macintosh HD:Desktop Folder:My Interesting File.txt" ------------ -------------- -----------------------
Drive Name Folder(s) Filename
Can you directly address a file several levels deep in the filesystem without using the MacOS interface itself to do so? The project I'm doing relies on the ability to do just that, and it would appear that I've hit a bit of a snag.You'll hit other snags doing it the way you want to, because the MacOS is not like DOS or Windows or Unix. (well, okay, OS X is like Unix, but that's not the point here...). If you're writing an application on the Mac, you should use the routines in the Mac Toolbox to do things... that way, your code will work on *any* Mac, not just the one(s) that are configured exactly like your test machine, with exactly the same hard drive name(s), exactly the same foldername(s), etc. Regardless, we are straying far from the topic of this list, since it has absolutely nothing to do with PHP. :)
If anyone can offer any suggestions or advice, I'd really appreciate it. Thanks in advance.INSIDE MACINTOSH: Files by Apple Computer, Inc. ISBN: 0-201-63244-6 $29.95 USA $38.95 CANADA - Brian ------------------------------------- Brian S. Dunworth Sr. Software Development Engineer Oracle Database Administrator The Printing House, Ltd. (850) 875-1500 x225 <brian@theprintinghouse.com> -------------------------------------