icon Device Specific Content
Created by Orckestra

How to target content to mobile and desktop devices

To show some content to visitors with mobile devices different from those with desktop devices:

  1. Edit a page.
  2. Insert the Orckestra.Web.Html.DeviceSpecificContent function ( Insert | Function) or add the following code:
    Expand code
  3. Set these parameters:
    1. Mobile (Mobile Content): The content to show to visitors with mobile devices.
    2. Desktop (Desktop Content): The content to show to visitors with desktop devices

Viewing content in mobile display mode

If you are using a desktop browser, you can still see what the content intended for mobile browsers will look (for testing purposes etc.) by switching to mobile display mode.

  1. Open the page with mobile content  in your browser.
  2. Append the query parameter cmsdisplaymode=mobile to the URL in the address bar, for example: http://contoso.com/Page?cmsdisplaymode=mobile
  3. Press ENTER.

Important. To view pages in mobile display mode, you should be logged into the CMS Console in the same browser.