MS bug: Error when creating new Search Navigation links in SharePoint 2013

In SharePoint 2013 you can create new Search Navigation links. This controls the options you get in the search dropdown box. OOTB, the options are Everything, People, Conversations and Video.

Let say you have a Portal site collection (http://portal), and a Search Centre site collection (http://portal/sites/search). If you want to configure Search Navigation links in your Portal site, and reuse the results pages in the Search Centre, you could use the following as the URL for one of your Search Navigation links: http://portal/sites/search/Pages/results.aspx. When you try to apply the setting however, you will get an error. In the ULS you will see that the error is “Cannot open “/sites/search/Pages/results.aspx”: no such file or folder.” The same error occurs if you enter an absolute URL (http://portal/sites/search/Pages/results.aspx), or a server-relative one (/sites/search/Pages/results.aspx).

So how do you overcome this? Well, the trick is to enter a URL that SharePoint will accept, then edit the link, and change the URL to what you want.

So when creating a new link, enter an absolute URL that is EXTERNAL to SharePoint, e.g. just enter http://www.google.com. Go ahead and apply the setting (that is click OK on the Search Settings page). Because the URL is external, SharePoint will not validate the link. Next, go back into the Search Settings page and edit the link. This time change the URL of the link to what you want. Go ahead and apply the setting again. This time SharePoint will happily accept it and your Search Navigation link will work as expected.

This is clearly a MS bug. I tested it on March 2013 Public Update and it is still there.

Advertisement

About Bernado

Based in Australia, I am a freelance SharePoint and Dynamics CRM developer. I love developing innovative solutions that address business and everyday problems. Feel free to contact me if you think I can help you with your SharePoint or CRM implementation.
This entry was posted in SharePoint 2013, Uncategorized. Bookmark the permalink.

4 Responses to MS bug: Error when creating new Search Navigation links in SharePoint 2013

  1. FB says:

    Amazing what slips through QC! Thanks for posting, I was stuck on this one, and this was hugely helpful.

  2. Markus Bosch says:

    Thank you so much! Trying to resolve it myself for almost 1 day! Your post helped very much!

  3. Toby says:

    Wow, that is helpful, thanks!

  4. Ragnar says:

    Had the same problem on Sharepoint Foundation 2013 and the trick that did it for me was using addasfirst and addaslast. These did not give an error while the add method was giving an error. And yes you can add search scopes also for sharepoint foundation with powershell. No way to modify it in UI but powershell worked as expected. Added 3 custom scopes to the search box. Only thing to look out for was that “This site” and “All results” scope went missing after i added my custom scopes and I could not get them back. But as you can create custom scopes with powershell then replacing the two of the missing ones should not be a problem.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s