What are two possible ways to achieve this goal?

You are developing a Web application that has two distinct UIs. One UI is targeted to desktop browsers. The other UI is targeted to mobile devices. The mobile devices might or might not support cookies and relative URLs. Users request the Default.aspx page. You need to redirect users to the appropriate UI, depending on whether they are using a mobile device or a desktop browser.
What are two possible ways to achieve this goal? (Each correct answer presents a complete solution. Choose two.)

You are developing a Web application that has two distinct UIs. One UI is targeted to desktop browsers. The other UI is targeted to mobile devices. The mobile devices might or might not support cookies and relative URLs. Users request the Default.aspx page. You need to redirect users to the appropriate UI, depending on whether they are using a mobile device or a desktop browser.
What are two possible ways to achieve this goal? (Each correct answer presents a complete solution. Choose two.)

A.
Add the following code segment to the Page_Load event of Default.aspx.
if (Request.Browser[“IsMobileDevice”] == “true” ) {
Response.Redirect(“MobileDefault.aspx”);
} else {
Response.Redirect(“DesktopDefault.aspx”);
}

B.
Add the following code segment to the Page_Load event of Default.aspx.
if (Request.Browser.Type == “MobileDevice”) {
Response.Redirect(“MobileDefault.aspx”);
} else {
Response.Redirect(“DesktopDefault.aspx”);
}

C.
Add the following node to the <system.web> element of the Web.config file.
<httpRuntime useFullyQualifiedRedirectUrl=”false” />

D.
Add the following node to the <system.web> element of the Web.config file.
<httpRuntime useFullyQualifiedRedirectUrl=”true” />



Leave a Reply 0

Your email address will not be published. Required fields are marked *