Archive for November, 2007

How to modify the Search Options dialog for the advanced people search

Wednesday, November 28th, 2007

While fooling around with the search result page I decided that it would be useful if my employees would be able to search explicit on these custom properties. I found a couple of tutorials on how to modify the "normal" advanced search page but not much on the people search page so I dug around a bit.

This is what I came up with (sorry for the rush job but I'm in a rush):

  1. Browse to your advanced people search page.
  2. Edit the page.
  3. Modify the People Search Box web part.
  4. Expand the Miscellaneous section.
  5. Click in the Properties text field and open it up in the "builder" (click the … to the right of the field).
  6. Add the custom property you want to be able to search on where you want it to show up in the form. Use the following syntax:
    <Property Name="YourPropertyHere" ManagedName="YourPropertyHere" ProfileURI="urn:schemas-microsoft-com:sharepoint:portal:profile:YourPropertyHere"/>
  7. Click OK to save the modified form.
  8. Test or publish your page as needed.

You should probably use Notepad or a similar text editor when editing the properties as some of the code that SharePoint spits out is quite messy.

EDIT: You need to modify both the search page (people.aspx) as well as the result page (peopleresults.aspx) if you want consistency in the search options.

Let me know if you have any problems with this and I'll do my best to help you out.

Why your modified search result doesn't include your custom properties

Wednesday, November 28th, 2007

I've been trying to get my modified people search result web part to behave for some time. My problem was that my custom properties wouldn't show up no matter what i did. I followed Henry Ong's guide to the T without success.

After some searching I finally stumbled upon this post and, more importantly, the final comment of the post wich solved the problem for me.

When adding custom properties to your search result you must use lower case in the XSL-editor!

If you use "BeginnerSkills" the column will not be found and you have to use "beginnerskills" as your parameter name – even if you called the column "BeginnerSkills" when you included it in the Results Query Options section.