Script to check the last date when Bing.com bot is indexing your site

On previous post, I create PHP script to check how many pages from your site is indexed in Bing.com search engine as part of fixing my old SEO statistic checker library. Now, we will check recent date where Bing.com search engine bot indexing your site. We will use scraping technique again, so, we can save our Azure Datamarket quota. How’s this useful for you? Well, it measured how much love Bing.com gave to your site.. šŸ˜›

bing.com bot query

Without more talk, here’s the full PHP source code:

Same as before, no fancy coding here. You can improve the data processing by using regular expression. You may ask, why we need to create our own file_get_contents as helper function, PHP already had one? You got it, we can use built-in file_get_contents function if we want. The reason why I create our own file_get_contents is to fool Search Engine that our query is legit and look natural (you know, we are doing illegal thing here –scraping search engine result– šŸ‘æ ). The other thing is that cURL has so many options that easily been set to our purpose (sure you can create stream context for built-in file_get_contents but is not that easy to understand to create it) .

How to use it:

Example result:

Fully working demo can be tested on: http://www.vrank.org/ on “Bing.com Bot” section.
As you can see, Bing.com bot is not really accurate. It only mention the date, Googlebot has more detailed info such as the time. Remember that the result might be different depending on your server location (where you run the script).

Leave a Reply

%d bloggers like this: