After upgrading to SharePoint 2010 some web part pages are showing an Error “Web Part Error: Access denied. You do not have permission to perform this action or access this resource.“. For sites without anonymous access, this can be mitigated with audience targeting of the web part. However, if that does not work or you need to have the page be anonymously accessible, but also have web parts on that page that have limited permissions, then you will need a different solution. This is not the perfect solution you are looking for, I am still waiting on Microsoft for that as well, but this is a simple jQuery trick that will hide that awful error and make the page render as you would expect (MOSS 2007 functionality). Just follow the following steps:
- Download the latest version of jQuery from their site: http://jquery.com/ and upload it to your server.
- At the bottom of the page add a content editor web part and make it hidden.
- Add the following code: