Windows IT Pro is the leading independent community for IT professionals deploying Microsoft Windows server and client applications and technologies.
  
  
  Advanced Search 


August 29, 2006

Outlook 2007: HTML Forms Are "Out;" CSS Is "In"

RSS
Subscribe to Windows IT Pro | See More Exchange Server and Outlook Articles Here | Reprints | Or get the Monthly Online Pass—only $5.95 a month!

Even though Microsoft Office 2007 isn't due for release for several months (late 2006 to volume license customers; early 2007 for retail and OEM customers), Microsoft is already documenting key changes to the product to help with the transition. The latest effort is a detailed description of which HTML elements and Cascading Style Sheets (CSS) features Outlook 2007 will support in email messages. The two-part MSDN article "Word 2007 HTML and CSS Rendering Capabilities in Outlook 2007" (see the URLs below) is must reading for any organization that sends newsletters or other standard or automated messages in HTML format. It tells you what you need to know to ensure that the messages look good in Outlook 2007, which has better CSS support than any earlier version.

In addition, Microsoft has released a validation tool to check HTML and CSS files in Visual Studio 2005, Office SharePoint Designer 2007, Expression Web Designer 2007, Macromedia Dreamweaver MX 2004, and Dreamweaver 8 for conformance with Outlook 2007's rendering capabilities. Organizations that use any of those applications to generate HTML content to send in messages (e.g., a newsletter) can use this new utility to help determine how that HTML will appear in Outlook 2007. You can download the tool, called Outlook HTML and CSS Validator at http://www.microsoft.com/downloads/details.aspx?familyid=0b764c08-0f86-431e-8bd5-ef0e9ce26a3a&displaylang=en .

What makes this effort both possible and necessary is that Outlook 2007's HTML rendering no longer depends on Microsoft Internet Explorer (IE). In earlier versions, the appearance of an HTML message in Outlook depended in part on which version of IE was installed on the system. Starting with Outlook 2007, the IE dependency goes away. Instead, just as Outlook 2007 uses Office Word 2007 as the sole editor for all types of Outlook items, it also uses Word 2007's rendering engine to display HTML messages. Thus, for the first time, it's possible to determine in advance precisely how Outlook will render an HTML message, regardless of what IE version the system has.

This lack of dependency on IE also shows itself in another way that security-conscious administrators will like. In earlier versions, Outlook had a View, View in Internet Zone command on its toolbar to allow a user to render an HTML message in the less secure Internet zone, for example, when the message contained a script. The [script] html tag (replace brackets with angle brackets -- <) is one among several HTML elements that are no longer supported in Outlook. The ability to render an email message in a less secure fashion remains, but the new command is Other Actions, View in Browser. If the user invokes that command, Outlook turns over any responsibility for dealing with the HTML message content to the user's browser, where it will be subject to the browser's security configuration. Thus, Outlook 2007 will never run a script in an HTML message.

Another blocked HTML tag is [form], along with the tags for all form controls. This means that you can't send an Outlook user an HTML message that contains a form with a Submit button to return results either in an email message or to a Web site. The data entry controls and Submit button won't even be visible to the Outlook 2007 user. To submit the form, the user would have to use the View in Browser command to view the HTML content in a browser.

This change definitely is going to affect some businesses. For example, Aliencamel.com, an email provider based in Australia, currently relies on the user interacting with an email-based form to release items from a spam quarantine folder. Aliencamel's Sydney Low says the company is exploring two possible solutions to accommodate Outlook 2007 users--either an add-in that provides a toolbar button to perform the same functionality or a change in its HTML code to add browser/rendering detection so that users see a message optimized for Outlook 2007. Ideally, Low says, "If the email is being displayed in Outlook 2007, it would say 'Click on this link to display the content,' but in other clients, an HTML form would be displayed."

If you want to give the validation tool a whirl, I recommend that you download the free trial version of the new Microsoft Expression Web Designer, a Web page editor designed from the ground up to work with CSS. Once you install Expression, follow the instructions in the "Word 2007 HTML and CSS Rendering Capabilities in Outlook 2007 – Part 2" article to add the ability to check HTML and CSS against the schema for Outlook. Open any HTML file that you want to test, and edit the HTML code to remove any attributes on the [html] tag. Then choose Tools, Compatibility Reports. Under "Check HTML/XHTML compatibility with," choose "HTML for Word 2007." Under "Check CSS compatibility with," choose "CSS Word 2007." Clear the box for "Run check based on doctype declaration in page if available." Then, click Check. Expression will display a compatibility report showing all the validation errors. Double-click any line in the report, and you'll go directly to the code with the validation error.

Compare the validation errors with the detailed list of supported and unsupported tags and attributes in the articles, especially Part 1, and you'll see how the rendering restrictions on HTML messages in Outlook 2007 add to Outlook's security. For example, the title attribute, which is used on Web pages to provide screen tips, isn't supported at all. This means the sender can't use a title attribute to hide the destination of a hyperlink; the screen tip for the link will always show the actual URL. Similarly, the [a] tag used for links doesn't support the class attribute. That approach prevents the sender from using a style to make some links look different from others. A link to external content in the background property of a style won't work at all (even if Outlook is otherwise configured to download external content for HTML messages).

This new validation tool isn't perfect. Because it depends on the compatibility-checking capability of the underlying HTML editor, it might not show a validation error for every unsupported style feature listed in the articles. For example, it didn't tell me about an external URL that I had included in the background property of my style for the [body] tag. But, combined with the detailed documentation in the article on Outlook 2007 rendering capabilities, organizations that want to start designing newsletters and other complex HTML-format messages for Outlook 2007 now can get a solid head start.

Word 2007 HTML and CSS Rendering Capabilities in Outlook 2007 (2 parts) http://msdn2.microsoft.com/en-us/library/aa338201.aspx http://msdn2.microsoft.com/en-us/library/aa338200.aspx

Microsoft Expression Web Designer Community Technology Preview 1 http://www.microsoft.com/products/expression/en/web_designer/wd_free_trial.aspx

End of Article



Reader Comments
Here's now to display text at
the top of an HTML message just for Outlook 2007 users. Add the following text just below the <body> tag.

<!--[if gte mso 12]><BR>To submit your selection using Outlook 2007 click
the <STRONG>Other Actions</STRONG> button, then <STRONG>View in
Browser</STRONG>.<BR><![endif]-->

Sue_Mosher December 12, 2006 (Article Rating: )


Here is a variation of the code above that allows you to specify HTML that will only be rendered for non-Outlook 2007 clients. So in our case, we can still display a site search box in our Marketing email for everybody not using Outlook 2007.

<!--[if gte mso 12]>
<div style="display: none;">
<![endif]-->

// Any HTML listed will not be displayed in Outlook 2007

<!--[if gte mso 12]>
</div>
<![endif]-->

And if you wanted to provide a link for those using Outlook 2007, you could also add:

<!--[if gte mso 12]>
<a href="">Search Our Site</a>
<![endif]-->

cromack March 06, 2007 (Article Rating: )


You must be a registered user or online subscriber to comment on this article. Please log on before posting a comment. Are you a new visitor? Register now




Top Viewed ArticlesView all articles
Command Prompt Tricks

One reader shares his tip for setting up the command prompt to reflect a remote path. ...

WinInfo Short Takes: Week of November 9, 2009

An often irreverent look at some of the week's other news, including some more Windows 7 sales momentum, some Sophos stupidity, Microsoft's cloud computing self-loathing, more whining from the browser makers, Zoho's "Fake Office," and much, much more ...

Understanding File-Size Limits on NTFS and FAT

A general confusion about files sizes on FAT seems to stem from FAT32's file-size limit of 4GB and partition-size limit of 2TB. ...


Exchange Server and Outlook Whitepapers Take Control of Your Email: Understand the Business Reasons for Email Storage Management

Continuous Data Protection and Recovery for Microsoft Exchange

Related Events WinConnections and Microsoft® Exchange Connections

Bail Out Your Exchange Environment

Check out our list of Free Email Newsletters!

Exchange Server and Outlook eBooks Spam Fighting and Email Security for the 21st Century

Understanding and Leveraging Code Signing Technologies

The Expert's Guide for Exchange 2003: Preparing for, Moving to, and Supporting Exchange Server 2003

Related Exchange Server and Outlook Resources Introducing Left-Brain.com, the online IT bookstore
Looking for books, CDs, toolkits, eBooks? Prime your mind at Left-Brain.com

Discover Windows IT Pro eLearning Series!
Clear & detailed technical information and helpful how-to's, all in our trademark no-nonsense format

Exchange & Outlook UPDATE eNewsletter
News, strategies, products, and developments in Exchange Server and Outlook messaging.

Windows IT Pro Home Register FAQ for Windows WinInfo News
Europe Edition About Us Contact Us/Customer Service Media Kit Affiliates / Licensing  
SQL Server Magazine Office & SharePoint Pro DevProConnections IT Job Hound
Left-Brain.com Technology Resource Directory asp.netPRO ITTV Windows SuperSite 
 
 Windows IT Pro is a Division of Penton Media Inc.
 © 2009 Penton Media, Inc. Terms of Use | Privacy Statement