Monday, October 31, 2011

Mobile view SharePoint 2010

By default "Mobile View" is turned ON for SharePoint 2010 sites. Mobile view works great for collaboration and intranet sites.  However if your company public website is on SP2010 then you want the pretty designs and colors to show.   

So..... how do we turn this off?  There is a "compat.browser" file in the root of your IIS site that needs modified.

Default path is "c:\inetpub\wwwroot\wss\VirtualDirectories\SharePoint80\App_Browsers\compat.browse"
You will see A TON of browsers in there.  The quickest is to change the most common such as iPhone or Android.  Shown below is an excerpt for Android

< !-- Android Safari Browser -- >
    < !-- sample UA "Mozilla/5.0(Linux; U; Android 1.5; zh-tw; HTC Magic Build/CUPCAKE) AppleWebKit/528.5+ (KHTML, like Gecko) Version/3.1.2 Mobile Safari/525.20.1" -- >
    < browser id="AndroidSafari" parentID="Safari2" >
        < identification  >
            < userAgent match="Android" / >
            < userAgent match="Mobile" / >
        < /identification >
        < capabilities >
            < capability name="isMobileDevice"                    value="true" / >
            < capability name="optimumPageWeight"                 value="1500"  / >

To turn OFF the Mobile Views and display the entire website change the "isMobileDevice" value from true to FALSE and save the file.  To get all the browsers start at the top and do a find for isMobileDevice moving through the entire file replacing true with false.