SPO and sometimes a Pop-Up appears and you do not want them?


You are navigating to a Document Library and chose Classic mode. Now you want to open the Windows Explorer view and Internet Explorer 11 asks you whether allowing pop-ups on this site or not.

image

And you may see in the lower area:
image

Disclaimer: Tested this first on 11/May/2018, but that could be changed, please be careful when you want to get a different behavior.

Background:
Each SharePoint Web-Page contains in the html header:
<meta http-equiv="X-UA-Compatible" content="IE=edge">
or
<meta http-equiv="X-UA-Compatible" content="IE=10">

This has a long history, why and what compatibility mode needs to use.

When "IE=edge" the pop-up appears. With "IE=10" a different method will be used to open the Windows Explorer.

To toggle the behavior, based on my findings on 11/May/2018, we can activate/deactivate a Feature. This Feature is called IE11OptOut and the GUID is "80E47777-D21C-46E0-9139-7C7741EB4B54"

Thanks to https://gist.github.com/joerodgers/b564e58db1dbbe2809027867b5505063 and I was able to lent this idea for this post.

################################################################################################
# THIS CODE-SAMPLE IS PROVIDED “AS IS” WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR
# FITNESS FOR A PARTICULAR PURPOSE.
#

# This sample is not supported under any Microsoft standard support program or service.

# The script is provided AS IS without warranty of any kind. Microsoft further disclaims all

# implied warranties including, without limitation, any implied warranties of merchantability

# or of fitness for a particular purpose. The entire risk arising out of the use or performance

# of the sample and documentation remains with you. In no event shall Microsoft, its authors,

# or anyone else involved in the creation, production, or delivery of the script be liable for

# any damages whatsoever (including, without limitation, damages for loss of business profits,

# business interruption, loss of business information, or other pecuniary loss) arising out of

# the use of or inability to use the sample or documentation, even if Microsoft has been advised

# of the possibility of such damages.

################################################################################################

 

##

## Testing toggle Feature IE11OptOut

##

 

[System.Reflection.Assembly]:: LoadFile( "C:\Program Files\SharePoint Online Management Shell\Microsoft.Online.SharePoint.PowerShell\Microsoft.SharePoint.Client.dll" ) | Out-Null

 

[System.Reflection.Assembly]:: LoadFile( "C:\Program Files\SharePoint Online Management Shell\Microsoft.Online.SharePoint.PowerShell\Microsoft.SharePoint.Client.Runtime.dll" ) | Out-Null

       

# Login Information for script

$username = "UserName@contoso.com"

$password = " MyOwnSecretPassword"

$url = "https://contoso.sharepoint.de/"

 

$securePassword = ConvertTo-SecureString $Password -AsPlainText -Force

 

# connect/authenticate to SharePoint Online and get ClientContext object..

$clientContext = New-Object Microsoft.SharePoint.Client.ClientContext($url)

$credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($username, $securePassword)

$clientContext. Credentials = $credentials

       

# Connect to SharePoint Online service

Write-Host "Logging into SharePoint online service." -ForegroundColor Green

       

# Feature is called "IE11OptOut" and the GUID we need

$FeatureID = "80E47777-D21C-46E0-9139-7C7741EB4B54"

       

# Enable feature, so that no pop-up appears when opening Windows Explorer

# Comment it to use the disable below

$clientContext.Site.Features.Add($FeatureID, $true, [Microsoft.SharePoint.Client.FeatureDefinitionScope]::Farm)

       

# Disable feature, so that pop-ups appears when opening Windows Explorer

# Un-Comment it to use the enable above

#$ClientContext.Site.Features.Remove($FeatureID, $true)


$clientContext.ExecuteQuery()

Write-Host "Script done." -ForegroundColor Green


You may need to do this for each Site Collection.

Resources:

https://blogs.msdn.microsoft.com/joerg_sinemus/2017/07/10/sharepoint-online-vanity-domain-powershell-csom-and-the-msoid-cname-record/

https://msdn.microsoft.com/en-us/pnp_articles/extending-sharepoint-online-for-germany-china-usgovernment-environments

In case you are in doubt how to use PowerShell together with SharePoint Online, please add “powershell sharepoint online first steps” into your Internet-Search engine of your choice and you will find resources to learn more about it.

    
    

Comments (0)

Skip to main content