Before you start customizing Communications Express, it is important to understand how to edit and deploy the JSP files.
The guidelines for customizing JSP files are as follows:
Do not edit JSP files directly in your production web server. Instead, make and test changes in a test environment.
Make a backup copy of the JSP file.
Edit the JSP file with any HTML and text editor. Typically, HTML editors do not work well for JSP files because of the amount of embedded Java code. In general, when editing a JSP file, be careful not to edit Java code.
After completing your edits, you can optionally compile the JSP file using a JSP aware IDE. Because the JSP file contains both HTML and Java code, this compilation ensures that you have not introduced any syntax errors.
Restart the web container for the changes to take effect.
This section describes various files that are critical and can break your customizations if they are not edited with caution. Some files often contain bug fixes. These changes can be lost if appropriate care is not taken.
The following table lists the files that should not be edited. These files often have bug fixes and are not needed for customization in most cases.
Table 2–1 List of files that often contain bug fixes
browser.js |
compRecipient.js |
dtree.js |
main.js |
form.js |
lookup.js |
mailui.js |
util.js |
searchusers.js |
setdomain.js |
smimeapplet.js |
The following table lists files that should be edited with caution. These files are highly readable and self-explanatory. Some of them have HTML code at the bottom. It is recommended that you limit your customization to the HTML portion. Also, do not add or modify any JavaScript functions. If you see a need for a new JavaScript function, create a new file and source it in the HTML code.
Table 2–2 List of files that should be edited with caution while customizing Communications Express
applet_fs_lr.html |
attach_fs_lr.html |
collect_fs_lr.html |
comp_fs_lr.html |
fldr_fs_lr.jsp |
mbox_fs_lr.jsp |
msg_fs_lr.jsp |
receipt_fs_lr.html |
searchmsg_fs_lr.html |
setpermission_fs_lr.html |
srchresults_fs_lr.html |
subscribe_fs_lr.html |
The following table lists files that are related to customizing global styles and fonts. A number of tools are available in the market that can help you find out values of a particular color. It is recommended that you edit these files to achieve the customizations for font and color. However, you can add new styles if you find it impossible to change the styles in these files.
Table 2–3 List of files related to global fonts and colors
dtree.css |
mail_css_ie5win.css |
mail_css_ns6up.css |
master-style.css |
master-style_ie5up.css |
master-style_ns4sol.css |
master-style_ns6up.css |
master-style_ns4win.css |
While customizing images in Communications Express it is recommended that you replace the existing images with the new ones without changing the file names. The file names of the image are read and cached by Communications Express and then rendered. If you want to change the names of the files, you have to change the name in the property files and then restart the web container. Replacing the image files with the new images while maintaining the same file names will avoid restarting of the web container.
The following list of files are customizable and configurable for Calendar and Address Book. It is assumed that the customization is performed before configuring Communications Express. The directories mentioned are relative to <install root>/lib/config-templates. If configured, the files are available in the location /var/opt/SUNWuwc on Solaris and /var/opt/sun/uwc on Linux.
Table 2–4 List of Customizable files for Calendar and Address Book
File Location |
Customizable Files |
Name used in the document |
---|---|---|
All the configuration files | ||
All i18n.properties files. i18n files are used to internationalize the interface for multiple languages | ||
themes.properties file | ||
All the .html, .xml and .xsl files | ||
All files such as .gif, .css, .html files | ||
All stylesheets (.css files) | ||
All image files (*.gif, *.jpg) | ||
.jsp files | ||
.jsp files | ||
.jsp files |