| |||||||||||||||||||||||||||||||||||
Sample: Chapter 5Doin' That E-Mail Thing
In This Chapter
E-mail enables users to instantaneously communicate with family and friends
throughout the world. E-mail is the so-called killer app of the Internet.
From its humble beginnings in the 1970s in the Unix community, e-mail has become the main reason many folks are connected to the Internet. Because Sun has always believed the network is the computer, it's no surprise that Solaris includes a number of different e-mail applications.
You may also want to check out some wonderful graphical and command-
line-based mail programs that aren't included in the standard Solaris 9
distribution. If you're interested, ask your system administrator to download
these free alternative applications that are ready to go on Solaris 9.
Regardless of which mail program you choose, sending and receiving e-mail
is a "killer skill" for anyone using the computer. This chapter offers an
introduction to working with e-mail from all three major environments: the
command line, the Common Desktop Environment, and GNOME.
Getting to Know MailerWithin the Common Desktop Environment, Mailer is the only mail program. Easily accessible from the Control Panel (click the inbox icon), it's likely that the program will launch the first time without any inbox or configuration, as shown in Figure 5-1.![]() Figure 5-1: Mailer with no messages Configuring the programTo configure the program, choose Mailbox -> New Mailbox. This opens the dialog box shown in Figure 5-2.You can set up a local mailbox, as discussed in this section, but Mailer will probably automatically recognize a local mailbox without any additional effort.
Figure 5-2: The Mailer configuration dialog box. An IMAP connectionMany Solaris users have their mail centrally stored on an IMAP server. To configure an IMAP connection, click the IMAP Server button near the top of the configuration dialog box. This opens the IMAP configuration dialog box, shown in Figure 5-3.
Figure 5-3: The IMAP configuration dialog box.
E-mail within Solaris is less susceptible to viruses than Windows
programs -- a reason to cheer, and a reason to be less paranoid
about the possible dangers lurking in e-mail attachments.
Using a Local Mailbox InsteadIf you don't have an IMAP account, you can specify your mailbox by clicking Local in the configuration dialog box and then searching for the specific mailbox in question, as shown in Figure 5-4.
Figure 5-4: Finding a local mailbox. Viewing the mailboxAfter the mailbox is identified, the program
Figure 5-5: Viewing a mailbox in Mailer.
From left to right, the Mailer toolbar contains these controls:
The message view window shows almost all headers in an e-mail message, screening out a few by default. If you want to hide more of the headers (such as X-UIDL and MIME-Version), search for message view preferences in the Help system (see the top-right corner of the Mailer menu bar). Mailer doesn't understand how to display messages using fancy formatting (typically HTML). If you receive lots of newsletters from Web sites, some messages may be unreadable in Mailer. Mailer recognizes and activates all Web site addresses it encounters in messages: In Figure 5-5, the URL for the Frontier Airlines Web site is in a different color. Click that, and the site opens in the Web browser. If the message has an attachment, the bottom pane shows the attachment in icon form, indicating the file's name and type. In Figure 5-5, Mailer recognizes an HTML format attachment and displays it. Right-click on the attachment to see a variety of options for saving, opening, or editing the file. Changing the sorting orderThe default setting of sorting messages from oldest to newest is usually a good choice. If you want to sort the messages by sender, subject, and so on, click the View menu, as shown in Figure 5-6.
Figure 5-6: Mailbox sorting options for Mailer.
If your mailbox contains a ton of messages, it may be useful to sort the
messages by sender and then select all of those messages and save them in a
new mailbox for that sender. Right-click the set of selected messages and
choose the option to save to a new mailbox.
Sending mailSending mail and responding to messages from others are the two most common Mailer tasks.Responding to a messageTo respond to a message, follow these steps:
Creating a new messageCreating a new e-mail message is just about as simple as replying to one:
Figure 5-8: Composing a new message in Mailer. Using Netscape MessengerThe alternative mail application for GNOME users (and CDE users, if desired) is a part of Netscape Navigator, as included with Solaris 9.Configuring an e-mail accountFollow these steps to configure an e-mail account:
Examining the Netscape windowNetscape 7 has an attractive display, as shown in Figure 5-13. The main window consists of four main areas by default:
Figure 5-13: Netscape 7 displaying new e-mail in the Inbox.
These are some of the folders in the upper-left pane:
Figure 5-14: The Netscape toolbar. Menu options and sortingThe available menus in Netscape are File, Edit, View, Go, Message, Tools, Window, and Help.Sorting is one of the many options available on the View menu, as shown in Figure 5-15. If you thought Mailer had a lot of mailbox sorting options, you'll be even more impressed with Netscape, which has 22 ways to organize your view. As with Mailer, the default sorting order in Netscape is likely to keep you happy for years of e-mail activity.
Figure 5-15: Sorting options and the View menu. You can access your Address Book by using the Tools menu (refer to Figure 5-9). The Address Book is a handy feature that enables you to manage a list of everyone with whom you send and receive e-mail.
Figure 5-16: The Message menu. Sending and responding to e-mailTo respond to an e-mail message, click the Reply button on the navigation bar, or choose Message --> Reply (refer to Figure 5-16). Figure 5-17 shows the beginning of my response to the note about the fishing scale.
Figure 5-17: Responding to an e-mail message. An important capability in Navigator is the spell checker. Click the Spell button on the navigation bar, and the program helps you avoid looking foolish with spelling hiccups. It can't help with grammar and word choice, but it is a terrific addition to the mail program. In the panel with the To address, the To button is actually a pull-down menu. You can specify that an address should actually be a Cc or Bcc address instead. Choose the Options menu, and you'll see a number of useful message options, as shown in Figure 5-18. You can encrypt and digitally sign messages, request a return receipt, and assign various priorities. If you're sending attachments, you can specify how the attachments should be packaged to ensure that they arrive at their destination in a useable format. You can safely leave the default configuration unless you're getting complaints from colleagues, in which case I recommend working with your system administrator to determine the ideal settings.
Figure 5-18: Message Options menu. The hybrid option might sound ideal, but remember this means that two copies of every message are sent to each recipient, a fancy HTML version and a plain text version. If your messages are a half-dozen lines, that's no big deal. But if you regularly send friends or colleagues 10 to 20 page messages, they might get testy about the waste of bandwidth and disk space. To write a new message, you just follow a simple process:
Figure 5-19: A new message, partially composed. Command Line CommunicationI stick with Berkeley mail, mailx, because it is included with Solaris 9 and has long been a part of the Sun operating system. It's not sexy but offers a surprisingly efficient mechanism for working with electronic mail.
Without additional software, mailx cannot interact with POP or IMAP
mailboxes. If you're using Solaris to process mail that comes via an ISP or is
sequestered on a central mail server until you grab it, you need to move up to
a graphical mail application, as profiled a bit later in this chapter.
Freeware POP and IMAP applications, most notably fetchmail, are available for Solaris, but you need to have your system administrator install them from the Internet. To find out more about fetchmail, Google it! Sending mail with mailxWhether or not you can receive your e-mail at the command line, it's likely you can send a quick message using mailx. By default, Solaris 9 is configured properly to send out messages if your system is on the Internet.To send a message, follow these steps:
... all the fish.
The EOT (end of text) is output when you press Ctrl+D. That's it. The
message is now on its way to the recipient somewhere on the Internet.
Dave EOT $ The mailx program offers some additional message capabilities, and you can generate a list of them with the sequence ~? on its own line. Rather than list them all, however, here are the most useful of the escape commands:
~?
To include the file gullivers.travels.txt at the end of a message, for example,
type ~r gullivers.travels.txt on its own line. The commands ~e and ~v are
useful for editing the message. (One uses your default editor, and the other
uses the vi editor, as discussed in Chapter 12.)
-------------------- ~ ESCAPES ---------------------------- ~b users Add users to Bcc list ~c users Add users to Cc list ~e Edit the message buffer ~f messages Read in messages, do not right-shift ~h Prompt for Subject and To, Cc and Bcc lists ~m messages Read in messages, right-shifted by a tab ~p Print the message buffer ~q,~Q Quit, save letter in $HOME/dead.letter ~r,~< file Read a file into the message buffer ~r,~< !command Read output from command into message ~R Mark message for return receipt ~s subject Set subject ~t users Add users to To list ~v Invoke (vi) display editor on message ~w file Write message onto file (no header) ~x Quit, do not save letter ~!command Run a shell command ~|,~^ command Pipe the message through the command ~? print this help message ----------------------------------------------------------- Working with incoming mailIf your system is configured so that your e-mail lives in a local mailbox, you can read and respond to your e-mail from the command line and never have to take your hands off the keyboard.To check your e-mail, use the mailx command but don't specify any arguments:
$ mailx
In the preceding example, 14 messages are in the mailbox /var/mail/taylor;
they're listed from oldest to newest.
mailx version 5.0 Sat Apr 6 14:57:29 PST 2002 Type ? for help. "/var/mail/taylor": 14 messages >O 1 Midwifery Today Thu Dec 12 02:19 1038/41234 E-News 4:38 - Obstetric I O 2 Robbie Dunlap Thu Dec 12 11:08 28/1210 <no subject> O 3 Lori Kats Thu Dec 12 12:16 72/4086 Donna Eden Suggests: Ask O 4 james@emissaryofli Fri Dec 13 02:20 41/3427 GREAT EXPERIMENT III O 5 Figureskater Fri Dec 13 10:25 107/3967 Re: S-Mart Order O 6 Lester, Emily Sat Dec 14 12:12 81/3511 RE: Hello! O 7 Colette Donahue Sun Dec 15 10:00 73/2806 RE: chicken pox O 8 Roy R. Dunlap Sun Dec 15 15:11 241/9813 Fwd: Fw: Re: one dollar O 9 news@606shot.com Mon Dec 16 11:49 122/5160 [NVIC] 5 in 1 vaccine liv O 10 Don Taylor Mon Dec 16 16:46 201/6620 (no subject) O 11 FrontierAirlines@f Tue Dec 17 04:38 80/4614 Happy Holidays! O 12 A Feehan Tue Dec 17 11:22 1113/82036 Hi O 13 james@emissaryofli Tue Dec 17 15:04 42/4034 Washington Mobilizes For O 14 Melissa Cohen Insu Tue Dec 17 15:56 51/1725 Re: cancellation of home ? The fields from left to right are
To read a message, type its index number at the ? prompt. For example, to read the message from Frontier Airlines (#11), type 11 at the prompt and then press Enter:
? 11
It's certainly not the most attractive e-mail message, but mailx does offer a
crude, functional interface. To respond to the message, type reply at the ?
prompt, or to ensure you're responding to the correct message, you can also
type reply 11:
Message 11: From FrontierAirlines@flyfrontier.com Tue Dec 17 04:38:04 2002 X-UIDL: b-;!!77K!!V\7"!\#k"! X-Sender: FrontierAirlines@flyfrontier.com Date: Tue, 17 Dec 2002 01:00:08 -0700 X-Sybari-Trust: b53a39e6 f6624f78 c4b24ea6 00000109 From: <FrontierAirlines@flyfrontier.com> To: "taylor@test-site.com" <taylor@test-site.com> Subject: Happy Holidays! MIME-Version: 1.0 --MWZAlternativeMessage Content-Type: text/plain Happy Holidays from Frontier Airlines! The employees of Frontier Airlines wish you a safe and happy holiday season. We hope the new year brings you joyous travels and much prosperity! Cancun and Mazatlan Sale Fares!! For all the exciting sale details and to make reservations, visit <http://www.frontierairlines.com>. Spirit of the Web Due to the high volume of air travelers expected over the weekend, Spirit of the Web fares will not be offered this week. Thank you for your continued support and look for a Spirit of the Web update on Tuesday, December 24, 2002. ?
? reply
To: sow@flyfrontier.com Subject: Re: Happy Holidays! Thanks for your lovely note. Happy Holidays to you too! Best, DT EOT ? Again, the EOT is displayed when you press Ctrl+D to denote the end of message input. With a reply, the program automatically grabs the recipient's address and subject from the original message. You can do more with mailx, and additional, more sophisticated e-mail programs are available for hard-core shell users, but you'll probably use a graphical mail program.
To find out more about mailx, check the extensive man page. To learn about
Elm, Pine, Mutt, and other alternative e-mail programs, check out
www.sunfreeware.com.
Note that this is but a sample chapter of the book Solaris
9 for Dummies. The book contains twenty chapters just as jam-packed with useful
information for everyone seeking to become productive with Solaris.
|
| ||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||