I have a problem with navigation elements being crawled on our SharePoint site. These elements come from a custom control that's used for building the site navigation, so the output is just html that might look like this simple example:
<div class="nav_root"> <ul class="nav_root_wrap"> <li class="SomeLink twoline first" id="SomeLink"> <a href="someLink.aspx">some link</a> </li> <li class="AnotherOption twoline second" id="AnotherOption"> <div class="flyoutMenu"> <a href="#">more links</a> ... </div> </li> </ul> </div>
It looks like adding the "noindex" class to the elements in the html should do the trick. However, because I don't have very much control over the css classes that get applied to this content on the server-side, I'm wondering if I can add some jquery like below to apply the css classes on the client-side.
Update2: It sounds like some folks have had luck creating a user control that prevents content from rendering for a particular user agent. Certainly an interesting option, though it's not what I'd hoped for: http://underthehood.ironworks.com/2010/05/sharepoint-search-partial-page-exclusion.html