Easy Code to Add Bing Site Search to Your Website
By Stephen Bucaro
If your website consists of more than just a few pages, it's important to have
a way for your visitors to search your website. There are several ways you can
accomplish this. One way is to use a pay site search company which will index
your site's contents and provide you code for a search box. This may give you
more control over the results returned for a specific search. But, the down side is,
you have to pay.
Another way to put site search to your website is to create your own index of
your site's contents and write your own search program. This gives you complete
control over the results returned. The down side, it's very complicated to write
code that can create an index and return results from that index based upon
a specific search term or phrase.
Another way is to simply put the code for a search box that calls the search
program of one of the major search providers, like Bing. Bing is Microsoft's
attempt to steal some of that lucrative search traffic from Google. The name
"Bing" comes from the phrase "Because it's not google". Bing is very powerful,
so if you're anti-Google, you may choose to implement a Bing search box.
The down side is that Microsoft is in the search business to make money,
so there will be some not from you're website results returned with your
The code for Bing site search is shown below, just paste this code into the
desired location on your website.
<form method="get" action="http://www.bing.com/search">
<input type="hidden" name="cp" value="1252" ?>
<img src="http://www.microsoft.com/presspass/_resources/images/img_windowsBingLogo.png" alt="Bing" /></a>
<input type="text" name="q" size="30" maxlength="255" />
<input type="submit" value="Search Site" />
<input type="hidden" name="q1" value="site:bucarotechelp.com" />
One thing you'll want to do is replace the text "site:bucarotechelp.com" with
the URL of your website (unless you want to post a form to search my website.
In that case thank you.) And just above that you may want to replace the text
"Search Site" with "Search (the name of your website)". Or just leave it "Search Site".
After you make those modifications, type in a search term or phrase and give
it a test. You can't get the services of a powerful search engine on your website
any easier or cheaper than this.
More HTML Code:
• HTML Select List Basics
• Creating a Subscript or Superscript with HTML
• How to Troubleshoot an HTML Table
• HTML List Basics
• HTML title Tag
• How to Use a Meta Redirect
• HTML5 Input Type - URL
• What is HTML?
• HTML Image Basics
• Divide a Table Into Head (thead), Body (tbody), and Footer (tfoot) Sections