<add> Element for <clientTarget>
Adds an alias for a specific user agent to an internal collection of user agent aliases.
<configuration>
<system.web>
<clientTarget>
<add>
<add alias="alias for user agent"
userAgent="user agent identification"/>
Required Attributes
Attribute | Description |
---|---|
alias | The name used to refer to a specific user agent. |
userAgent | The user agent's identification. |
Remarks
The collection of user agent aliases indicates the target user agents that ASP.NET server controls should render content for.
Example
The following example adds four user agent aliases to the internal user agent alias collection.
<configuration>
<system.web>
<clientTarget>
<add alias="ie5" userAgent="Mozilla/4.0 (compatible;
MSIE 5.5; Windows NT 4.0)"/>
<add alias="ie4" userAgent="Mozilla/4.0 (compatible;
MSIE 4.0; Windows NT 4.0)"/>
<add alias="uplevel" userAgent="Mozilla/4.0 (compatible;
MSIE 4.0; Windows NT 4.0)"/>
<add alias="downlevel" userAgent="Unknown"/>
</clientTarget>
</system.web>
</configuration>
Requirements
Contained Within: <system.web>
Web Platform: IIS 5.0, IIS 5.1, IIS 6.0
Configuration File: Machine.config, Web.config
Configuration Section Handler: System.Web.Configuration.ClientTargetSectionHandler
See Also
<clientTarget> Element | @ Page | ASP.NET Configuration | ASP.NET Settings Schema