Quantcast
Channel: SharePoint 2010 - Development and Programming forum
Viewing all articles
Browse latest Browse all 11571

Hide Sharepoint Version History From Context Menu

$
0
0

Hi Guys,

I want to hide sharepoint Version History from Context Menu only on Document Library.

I have Used Used following script but it is not working on IE7 and IE8 browser.

<script type="text/javascript">

window.onload = function() 
{

   //this will return the current URL. if url contains /forms/ then it will be a Document Library.

    var strurlValue = document.location.toString().toLowerCase();

    var found = strurlValue.match("/forms/");
        
    if( found != null)
    {
        AddVersionsMenuItem = function (m,ctx) { } // to hide from Contaxt Menu
    }    
        
    
}</script>

Thnx in advanced.

Regards,

Pravin Dhulap


Viewing all articles
Browse latest Browse all 11571

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>