Robert McLaws: FunWithCoding.NET

Public Shared Function BrainDump(ByVal dotNet As String) As [Value]

News

<script type="text/javascript"><!-- google_ad_client = "pub-4330602465258980"; google_hints = "ASP.NET, VB.NET, C#, C#.NET, WindowsForms, .NET Framework, VS2005, Visual Studio, XAML, WinFX, Windows Workflow, WPF, WCF, Atlas, NetFX3, Visual Studio Orcas"; google_ad_width = 120; google_ad_height = 240; google_ad_format = "120x240_as"; google_ad_type = "text_image"; google_ad_channel ="4997399242"; google_color_border = "B6C9E7"; google_color_bg = "EFEFEF"; google_color_link = "0000FF"; google_color_text = "000000"; google_color_url = "002C99"; //--></script> <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script>
<!--
-->

You should feel free to challenge me, disagree with me, or tell me I'm completely nuts in the comments section of each blog entry, but I reserve the right to delete any comment for any reason whatsoever. That said, I will most likely only delete abusive, profane, rude, or annonymous comments, so keep it polite, please.

Blogroll

Cool .NET Articles

My .NET Tools

My Builder.com Articles

My MSKB Articles

Adding OpenSearch for your CommunityServer Site

So last night, I had this really random idea to create an OpenSearch Provider for LonghornBlogs.com. That way I could search my site from IE7's search box. In the process, I discovered that my search is broken there, so I decided to create them for several of the main Microsoft community sites instead:

Maybe Telligent will create an OpenSearch directory for all the CS communities out there. We'll have to wait and see. Anyways, if you want to write your own, I'll show you how!

Writing Your Own Provider:

Here's what a CS 2.0 OpenSearch provider looks like:

<?xml version="1.0" encoding="UTF-8" ?>
<OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/">
 <ShortName>Your Name Here</ShortName>
 <Description>Your Description Here</Description>
 <Url type="text/html" template="http://www.yoursitehere.com/search/SearchResults.aspx?q={searchTerms}&amp;o=Relevance" />
</OpenSearchDescription>

When you form your URLs, make sure they are UrlEncoded first, or they'll throw an error.

Installing Your OpenSearch Provider:

You'll have to add a hyperlink to the provider on your website. Just use the following syntax for your link: <a href="#" onClick="window.external.AddSearchProvider(&quot;http://www.yoursitehere.com/yoursearchprovider.xml&quot;);">

That's it! It's really very simple. Of course, you can add a lot more information to your OpenSearch provider. Amazon's A9 has all the details.

Comments

Robert McLaws: FunWithCoding.NET - Windows Vista Edition said:

If you've ever wanted to search blogs.msdn.com from your IE7 toolbar, I have just the solution for you:...
# June 14, 2006 12:27 PM

Adding OpenSearch for your CommunityServer Site said:

Pingback from  Adding OpenSearch for your CommunityServer Site

# November 27, 2007 3:56 AM