Tuesday, January 25, 2011

Ping Your Sitemap To Search Engine (Google, Yahoo, Bing, Ask)

XML sitemaps are used to inform search engines about the web pages available to crawl on your website or blog. Basically search engines find all web pages by navigating links on your websites but sitemaps enhance search engine crawling by providing explicit link and content about the specific urls on your website. When we submit sitemaps to search engine then they don’t ensure that your web pages will be indexed/searched, but they increase both the probability and speed of indexing/searching.
Whenever you have new content on your website or blog, it is necessary to make sure that the search engines know about your new web pages and post to get the content indexed as soon as possible. This can be done by pinging your xml sitemap to search engines. There are many search engines and services you can ping your sitemap to, but according to me, it is necessary to submit your sitemap to major search engines like Google, Yahoo, Ask, Bing.
So create the XML sitemap of your website and also compressed your sitemap in .gz format. Now you can alert the search engines in two ways.
1. By Manually
2. By Cron Jobs (For Web Developers)
By Manually: You have to type a specific formatted url in browser of your sitemap.
By Cron Jobs: Whenever a new sitemap is available for your website then submit your sitemap using your coding language by opening connection in background like curl. This method is used by web developers.
Suppose the address of your sitemap is http://www.example.com/sitemap.xml.gz

Ping Google
Google is the biggest search engine, and you will have to submit your url to Google.
The ping url for Google is
http://www.google.com/webmasters/sitemaps/ping?sitemap=http://www.example.com/sitemap.xml.gz

Ping Yahoo
Their ping url for Yahoo is
http://search.yahooapis.com/SiteExplorerService/V1/updateNotification?appid=YahooApplicationID&url=http://www.example.com/sitemap.xml.gz
Where YahooApplicationID is a unique id of your website generated by Yahoo. To get the id of your website, Please Click Here

Ping Bing
Their ping url of Bing is
http://www.bing.com/webmaster/ping.aspx?siteMap=http://www.example.com/sitemap.xml.gz 

Ping Ask
Their ping url of Ask is
http://submissions.ask.com/ping?sitemap=http://www.example.com/sitemap.xml.gz

Submit Sitemap Using Curl (Code for PHP Developers)
$PingUrl = "http://www.google.com/webmasters/sitemaps/ping?sitemap=http://www.example.com/sitemap.xml.gz";
$curl_handle=curl_init();
curl_setopt($curl_handle, CURLOPT_URL, $PingUrl );
curl_setopt($curl_handle,CURLOPT_RETURNTRANSFER,1);
$buffer = curl_exec($curl_handle);
curl_close($curl_handle);

1 comment:

  1. I recently came accross your blog and have been reading along. I thought I would leave my first comment. I dont know what to say except that I have enjoyed reading. Nice blog. I will keep visiting this blog very often.

    ReplyDelete