NIU Department of Mathematical Sciences
When transferring files between similar systems the distinction is not crucial; but on different machines the format of text files is slightly different. This makes it necessary to use the right transfer mode - text or binary. Text files sent in binary mode might have incorrect newline characters and other "gremlins" in them, while binary files sent in text mode will most likely be unuseable because all the highest bits will be stripped off. This applies to network transfers (FTP) and ordinary modem ones (Kermit, Zmodem etc.) Consult the documentation for a specific program to see how the transfer mode can be set.
Recognizing the type of various files is largely a matter of experience. To help us in this, files are customarily given names with extensions which indicate what the file contains. Executable programs (.Bin), image files (.jpg, .gif), sound data (.snd, .au), and most word processor documents are all binary files. Text (.txt, .asc), PostScript (.ps), TeX (.tex) are all ASCII. Here is a more complete list.
In the Macintosh world there is one more twist. Files are stored on disk in two parts: the data fork and the resource fork (the latter contains icons, information about the program which created the file, etc. When you see a Macintosh binary file (usually with extension .Bin) stored on a system such as Unix or Windows NT, you can be sure that those two forks have been "collapsed" and have to be restored during download. You then must use a variation of the binary transfer mode - so called MacBinary transfer. All Mac applications which can transfer files allow the user to select this option.
You can avoid most of this hassle by using a modern Web browser to access FTP archives. The file type will be automatically recognized in most cases. When you see a link which represents something that you want to download to local disk rather than view on the screen, simply press one of the control keys while clicking on the link. The key differs from system to system and between browsers. For example, in Netscape on a Mac press the Option key.
Assuming that the server you are accessing is correctly configured, even the strange "two forked" Mac files should download properly. Moreover, your browser can be instructed to automatically unravel encoded and archived files (see below) by means of a "helper application" such as StuffIt Expander.
Some such archives are "self-extracting": they are regular Mac applications which can be run by double-clicking on them, and the result will be a new folder on your disk.
Other archives require a special "unpacker" program. The most common of these have the extension .sit and can be unpacked using the utility StuffIt Expander, available for a MacBinary download here. If you'll be searching for Mac software on-line, you won't go far without it.
Another important use of BinHex'ed files is to "bootstrap" your network connection; for example, if you need some piece of software which is available on the Internet but your Mac isn't connected yet, you can use a PC and a DOS floppy, or a straightforward modem connection, to download the necessary files in BinHex (ASCII) format, and then unpack them on your Mac's disk.
All this sounds quite complicated, but don't worry: if you have a relatively new version of a decoding/unwrapping utility on your disk, then most modern network software (Netscape, Fetch) will automatically invoke it when it's necessary to process a file which you just downloaded.
Back to the NIU Math Department Web page