Turn off more accessible mode Blogs > Mark Eichenberger's SharePoint Blog
Sign In

Mark Eichenberger's SharePoint Blog

Go SearchAdvanced Search
Blog
About Me
Big List of Links

Categories
SharePoint
Web Parts
Security
Management
Training
Me
View in Web Browser/_layouts/images/ichtmxls.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&DefaultItemOpen=10x00x1FileTypexlsx255
View in Web Browser/_layouts/images/ichtmxls.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&DefaultItemOpen=10x00x1FileTypexlsb255
Snapshot in Excel/_layouts/images/ewr134.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&Snapshot=10x00x1FileTypexlsx256
Snapshot in Excel/_layouts/images/ewr134.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&Snapshot=10x00x1FileTypexlsb256
Other Blogs
Lawrence Liu's Report from the Inside
Microsoft SharePoint Products and Technologies Team Blog
View in Web Browser/_layouts/images/ichtmxls.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&DefaultItemOpen=10x00x1FileTypexlsx255
View in Web Browser/_layouts/images/ichtmxls.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&DefaultItemOpen=10x00x1FileTypexlsb255
Snapshot in Excel/_layouts/images/ewr134.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&Snapshot=10x00x1FileTypexlsx256
Snapshot in Excel/_layouts/images/ewr134.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&Snapshot=10x00x1FileTypexlsb256
Links
Photos
Archive
Archive (Calendar)
View in Web Browser/_layouts/images/ichtmxls.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&DefaultItemOpen=10x00x1FileTypexlsx255
View in Web Browser/_layouts/images/ichtmxls.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&DefaultItemOpen=10x00x1FileTypexlsb255
Snapshot in Excel/_layouts/images/ewr134.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&Snapshot=10x00x1FileTypexlsx256
Snapshot in Excel/_layouts/images/ewr134.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&Snapshot=10x00x1FileTypexlsb256
Mark Eichenberger's SharePoint Blog > Posts > Restricting the use of Web Parts

10/5/2007

Restricting the use of Web Parts

Sometimes, you just don't want certain people adding web parts to a page. Content Editor and Image Viewer web parts are no big deal, but there are circumstances where the editing settings for certain web parts are beyond the skills of many page/site designers.

In SharePoint 2003/WSS v2, you could only remove the web parts and add them in later via the Import command. You can still do that, but with the advent of item level security in MOSS 2007/WSS v3, why not alter the permissions in the Web Part Gallery?

The Web Part Gallery is just another type of SharePoint library. It allows you to add items, modify properties -- and manage permissions. The Web Part Gallery exposes web parts to the entire site collection so managing permissions will apply to the top level site and any sub sites.

For example, let's say you don't want Designers adding the SAP IView web part to a page because it may require additional settings that are not readily available to anyone outside the SAP group. (Another good example would be any of the BDC web parts because you're really creating a mini-application by combining these on a page.) When you go to add a web part to a zone, you see something similar to the following screenshot.

To hide the IView web part -- or any others -- from specific people or roles, follow these steps.

  • Click Site Actions / Site Settings
  • If you are not already at the top level site collection, click on Go to top level site settings under the Site Collection Administrator heading.
  • Under the Galleries heading, click Web Parts and you will see a list of available web parts (.dwp files) in the list (see below).

  • Click the Edit icon next to IViewWebPart.dwp file
  • Click the Manage Permissions toolbar button
  • Click Actions / Edit Permissions and click OK when prompted
  • Check the box(es) next to any users/groups you do not want to see the web part
  • Click Actions / Remove Permissions and click OK when prompted

Next, have someone else with the demoted permissions go to one of the sites within the site collection, edit the page, and click to add a web part. When scrolling through the list, the IView web part should be gone and should appear as shown below.

****IMPORTANT NOTE****

This set of actions will hide the web part when someone wishes to add a part to a page. After the web part is on the page, anyone with edit page permissions will be able to alter the web part properties, and they retain the right to remove the web part from the page.

Posted at 4:08 PM by Mark Eichenberger | Category: Web Parts; Security; SharePoint | Permalink | Email this Post | Comments (4)
View in Web Browser/_layouts/images/ichtmxls.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&DefaultItemOpen=10x00x1FileTypexlsx255
View in Web Browser/_layouts/images/ichtmxls.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&DefaultItemOpen=10x00x1FileTypexlsb255
Snapshot in Excel/_layouts/images/ewr134.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&Snapshot=10x00x1FileTypexlsx256
Snapshot in Excel/_layouts/images/ewr134.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&Snapshot=10x00x1FileTypexlsb256

Comments

Not All the Web Parts show up in the Web Parts Gallery Page

Thanks for the post.

 

I attempted this method of hide all the unnecessary Web Parts.

When I go to Webpart Gallery page I see about 55 Web Parts but When I go to a site and edit page, and then click to Add Web Part I see about 70 Web parts. I understand some of them are coming from List/Libraries on the page, but some of them Out Of the Box present here are not present on the Web Part Gallery Page. for example:

 

Excel Web Access

 

 

 

FYI - I have applied Team Site Template for my Site Collection, and then activated Enterprise Publishing Infrastructure Feature to take advantage of some handy features.

 

 

 

Wondering, what could be the issue? I would appreciate your feedback at jaxy555@yahoo.com

 

Thanks,

 

Jaxy

 

at 4/19/2008 9:01 AM

Re: Not All the Web Parts show up in the Web Parts Gallery Page

I'm not sure what your issue is that's causing the web parts to continue to show up.  I've tried this in a number of environments and it's worked successfully every time.

I have tried it with enterprise publishing infrastructure as well and it worked fine.

Double-check the permissions you are applying to the web parts and make sure the user you login as to add them definitely doesn't have rights to see the web parts.

Good luck,

Mark

Mark Eichenberger at 4/29/2008 12:53 PM

Restricting at the Site or Subsite Level as well

I see your article only restricts at the Site Collection level.  What about the subsite level?  Can this be accomplished?  Some of our sites we want to show web parts, and other sites we don;t (and they are all in the same site collection)
at 5/2/2008 2:11 PM

Re: Restricting at the Site or Subsite Level as well

Sorry, there is no way using this method to restrict the web parts at a site/sub site level.
 
The only other valid approach is to come up with a custom site definition for the sites you want to restrict and remove them from the site definition.  Then create sites from that definition.
 
But this action removes the web parts for everyone - not just specific people.
Mark Eichenberger at 5/8/2008 4:40 PM

Add Comment

View in Web Browser/_layouts/images/ichtmxls.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&DefaultItemOpen=10x00x1FileTypexlsx255
View in Web Browser/_layouts/images/ichtmxls.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&DefaultItemOpen=10x00x1FileTypexlsb255
Snapshot in Excel/_layouts/images/ewr134.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&Snapshot=10x00x1FileTypexlsx256
Snapshot in Excel/_layouts/images/ewr134.gif/blogs/MarkE/_layouts/xlviewer.aspx?listguid={ListId}&itemid={ItemId}&Snapshot=10x00x1FileTypexlsb256
Items on this list require content approval. Your submission will not appear in public views until approved by someone with proper rights. More information on content approval.

Name (required) *


Subject


Body (required) *

Attachments
Use this page to add attachments to an item.
Name