Saturday, February 28, 2015

Hide Overwrite existing files Option of Upload Document Page in SharePoint 2010

Requirement:
Uncheck and Hide Overwrite existing files Option in Upload Document Page of SharePoint 2010.

hide overwrite existing files option in sharepoint 2010

Solution:
  • Login to your SharePoint Web Front End Server, Navigate to: "C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\template\layouts" folder
  • Make a backup of "Uploadex.aspx" file and open it in Notepad.
  • Search for text </asp:Content> from the top and Insert the below code in it.
  • <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js" type="text/javascript"></script>
    <script type="text/javascript">
     $(document).ready( function () {
     if(location.href.indexOf('globalfunctions/credit/_layouts/Upload.aspx') >= 0) {
    
                $("input[id$='OverwriteSingle']").removeAttr('checked');
                $("input[id$='OverwriteSingle']").hide();
                $("label[for$='OverwriteSingle']").hide();
                $("a[id$='UploadMultipleLink']").hide();
    
          }
     });   
    </script>
    
  • Save and close the uploadex.aspx file. Repeat these steps in all your web front end servers if you have more than one.
My requirement is to hide overwrite existing files and upload multiple files options for only a particular subsite, so I've wrapped the code inside "IF" condition. Here is the Result of hidden overwrite existing files option and multiple upload link in upload page:
hide upload multiple files



You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.
*Sponsored


Check out these SharePoint products:

No comments :

Post a Comment

Please Login and comment to get your questions answered!

You might also like:

Related Posts Plugin for WordPress, Blogger...