Working with Mail Portlet
For the purpose of this article, we will use an intranet website called book.com which is created for a fictions company named “Palm Tree Publications”.
In order to let employees manage their emails, we can use the Liferay Mail portlet. As an administrator of “Palm Tree Publications”, you need to create a Page called “Mail” under the Page, “Community” at the Book Lovers Community Public Pages and also add the Mail portlet in the Page, “Mail“.
Experiencing Mail Management
First of all, login as “Palm Tree“. Then, let’s do the above as follows:
- Add a Page called “Mail” under the Page “Community” at the Book Lovers Community Public Pages, if the Page is not already present.
- If the Mail portlet is not already present, add it in the Page, “Mail” of the Book Lovers Community where you want to manage mails. You will see the Mail portlet as shown in the following figure.
Let’s assume that we set up the mail domain as “cignex.com” in the Enterprise Admin portlet for testing purposes, as we have a mail engine with this mail domain already. Of course, you could set up the mail domain as “book.com“, or something else, if you had a mail engine with this mail domain in your hand.
As an editor of the editorial department, “Lotti Stein“, you may want to manage your mails in the mail domain, “cignex.com“. You can first choose a user name for your personal company the email address, say “admin1234” and register. Let’s do it as follows:
- Login as “Lotti Stein“.
- Go to the Page “Mail” under the Page, “Community“, at the Book Lovers community Public Pages.
- Locate the Mail portlet.
- Input the value for User name as “admin1234“.
- Click the Register button.
Your new email address is “email@example.com”. This email address will also serve as your login, as shown in the following figure.
You can now check for new messages in your inbox, by clicking the Inbox link first. Then, you can view the Unread messages, and either Check Mail or create a New mail, as shown in the following figure:
You can go to the Page of Mail management by clicking on any link of Unread Messages, or Check Mail button or New button. Further, you can manage emails through the Mail portlet of your current account. Email management includes the following features (as shown in the following figure):
- Create a New email.
- Check Mail.
- Reply to an email.
- Reply All emails.
- Forward emails.
- Delete emails.
- Print emails, and
Note that the first email with the subject, “Users in Staging server“, is sent through the SMS Text Messenger portlet. For more details, refer to the forthcoming section.
How to Set up Mail Server?
In order to make the Mail portlet work, we have to set up a mail server with IMAP, POP and SMTP protocols. Suppose that the Enterprise “Palm Tree Publications” has a mail server with the domain “exg3.exghost.com“, an account “firstname.lastname@example.org/admin1234“, and protocol IMAP, POP and SMTP. As an administrator, you need to integrate this mail server with IMAP, POP and SMTP protocol in Liferay. Let’s do it as follows:
- Find the file ROOT.xml in $TOMCAT_DIR/conf/Catalina/localhost.
- Find the mail configuration first.
- Then configure it as follows:
In short, a Mail portlet is an AJAX web-mail client. We can configure it to work with any mail server. It reduces page refreshes, since it displays message previews and message lists in a dual pane window.
How to Set up Mail Portlet?
If you have proper Permissions, you can change the preferences of the Mail portlet. To change the preferences, you can simply click the Preferences icon to the upper right of the Mail portlet.
With the Recipients tab selected, you can find potential recipients from the Directory (Enabled or Disabled) and the Organization (My Organization or All Available). Click the Save button after making any changes.
Using the Filters tab, you can set the values to filter emails associated with an email address to a Folder. Click the Save button after making any changes.
Note that the maximum number of email addresses is ten. This number is also configurable at the portal-ext.properties
Similarly, the Forward Address tab allows all emails to be forwarded to the email address you want. Enter one email address Per Line. Remove all entries to disable email forwarding. Select Yes to leave, or No to not leave a copy of the forwarded message. Click the Save button after making any changes.
Further, the Signature tab also allows you to set up your signature using HTML text editor. The signature you have set up will be added to each outgoing message. Click the Save button after making any changes.
The Vacation Message tab allows you to set up vacation messages using HTML text editor. The vacation message notifies others of your absence (as shown in the following figure). Click the Save button after making any changes.