I'm running the check-for-user-in-group from xslt within the people.aspx page and running into something I'm not sure about. If the logged-on user running the page does not have at leaset "Design, Limted Access" permission, the code will not run. If they do, it will. This does not make sense as it would seem that all users should be able to run this. So, I wanted to know if anyone else is esperiencing this. This is the code I'm running.
<script type="text/javascript"> $(document).ready(function() { $('div[id^="ObjectToHide"]').hide(); $().SPServices({ operation: "GetGroupCollectionFromUser", userLoginName: $().SPServices.SPGetCurrentUser(), async: false, completefunc: function(xData, Status) { if($(xData.responseXML).find("Group[Name='Group Name']").length == 1) { $('div[id^="ObjectToHide"]').show(); } else { $('div[id^="ObjectToHide"]').hide(); } } }); }); </script>
<script type="text/javascript"> $(document).ready(function() { $('div[id^="ObjectToHide"]').hide(); $().SPServices({ operation: "GetGroupCollectionFromUser", userLoginName: $().SPServices.SPGetCurrentUser(), async: false, completefunc: function(xData, Status) { if($(xData.responseXML).find("Group[Name='Group Name']").length == 1) { $('div[id^="ObjectToHide"]').show(); } else { $('div[id^="ObjectToHide"]').hide(); } } }); }); </script>