[Expand]General Information
[Expand]WinForms Controls
[Collapse]ASP.NET Controls and MVC Extensions
 [Expand]Prerequisites
 [Expand]What's Installed
 [Collapse]Common Concepts
  [Expand]Web.config Modifications
  [Expand]Callback Exception Handling
  [Expand]Client-Side Functionality
  [Expand]Cookies Support
  [Expand]Appearance Customization - Theming
   Icon Collection
  [Expand]Performance Optimization
  [Expand]CSS Image Sprites
   Supported Document Types
  [Expand]Accessibility Support
   Right to Left Support
   HTML Encoding
  [Expand]SharePoint Support
   Mobile Support
  [Expand]Office Document Management
   Cloud Storage Account Management
  [Expand]Web Farm and Web Garden Support
 [Expand]ASP.NET WebForms Controls
 [Expand]ASP.NET MVC Extensions
 [Expand]Localization
 [Expand]Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report and Dashboard Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

Supported Document Types

The <!DOCTYPE> declaration specifies to the browser the HTML version used for the document, and this declaration is a strict requirement for DevExpress ASP.NET controls. DevExpress ASP.NET products render HTML code that conforms to the look and feel of web pages based on the following document types.

  • XHTML 1.0 Transitional. This document type definition contains all HTML elements and attributes, including presentational and deprecated elements (like font). Framesets are not allowed. The markup must also be written as a well-formed XML.

  • XHTML 1.0 Strict. This document type definition contains all HTML elements and attributes, excluding presentational and deprecated elements (like font). Framesets are not allowed. The markup must also be written as a well-formed XML.

  • HTML5 - The current major version of the HTML standard.

HTML code generated by DevExpress ASP.NET controls is designed to fully comply with the XHTML 1.0 Transitional specification. In other supported document types, the code may work well but might not pass markup validation. DevExpress controls are designed to render 100% XHTML compliant code in most control usage scenarios, with a few exceptions – as noted below.

  1. Certain browsers do not fully support valid XHTML markup, so there is a lack of cross-browser compatibility.
  2. Some advanced features cannot be implemented with valid XHTML code, so you are required to choose between using the feature or maintaining valid code.
Note

If there is no DOCTYPE element or the DOCTYPE is unclear, the browser renders a page in Quirks mode. Additionally, you will not be able to use an HTML Validator to check page coding, because validation requires a DOCTYPE declaration.

Note

The doctypeMode option in the web.config file and the page's DOCTYPE should be set to the same document type definition (XHTML or HTML5).

Expanded XHTML compliance issues

You may encounter the following XHTML compliance issues.

ASPxObjectContainer Component

Under certain circumstances, the ASPxObjectContainer component renders the <embed> tag, which is invalid according to the XHTML specification. This tag is required for cross-browser compatibility, since the <object> tag (which is a valid replacement for the <embed> tag) is not correctly processed by some browsers.

The <embed> tag renders if the control's content is:

  • a video or audio file;
  • a flash animation file (if the component's ObjectProperties.EmbedMethod property is set to TwiceCooked).

Image Alignment Attributes

Some DevExpress ASP.NET controls expose properties that specify alignment for embedded images. These properties are of the ImageAlign type, which is an enumeration. Although this is a standard ASP.NET enumeration, some of its values are invalid based on the XHTML specification (e.g., AbsBottom, AbsMiddle, Baseline and TextTop are invalid values).

Expanded See Also

Is this topic helpful?​​​​​​​