<%@ Page Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<title>IE9 Mode Test</title>
<script type="text/javascript">
function testScriptFeatures() {
var r = [];
r.push("IE9 Test->typeof document.body.style.opacity = "
+ typeof document.body.style.opacity);
r.push("IE8 Test->typeof window.JSON = "
+ typeof window.JSON);
r.push("IE7 Test->typeof document.body.style.maxWidth = "
+ typeof document.body.style.maxWidth);
document.getElementById("dvInfo").innerHTML = r.join("<br />");
}
</script>
<style type="text/css">
div
{
font-size: 9pt; font-family: Verdana;
margin: 5px; padding: 5px; width: 400px;
border: 1px solid red;
border-radius: 10px; /* IE9 */
}
div:first-child /* IE7+ */
{
background-color: yellow;
}
#dvInfo { background-color: #dddddd; }
#spnUA:before /* IE8+ */
{
content: "****";
}
</style>
</head>
<body onload="testScriptFeatures()">
<div><span id="spnUA">
User Agent: <%=Request.UserAgent%>
</span></div>
<div id="dvInfo"></div>
<div>Time: <%=DateTime.Now.ToString("HH:mm:ss")%></div>
</body>
</html>