Forum Moderators: open

Message Too Old, No Replies

dynamic list of search engine user-agents w. Ajax sites

         

besson3c

3:05 am on Nov 12, 2006 (gmt 0)

10+ Year Member



I'm looking for a way to consult some sort of dynamic list of search engine robot/crawler user-agents so that I can provide a separate version of my pages that can be crawled by Google. I'm doing a lot of Ajax these days, and according to Google's FAQ it is best to rely on Javascript to provide content you would like a search engine to be able to crawl.

In the past, I've just done a quick manual check of some common User Agents (Google and a few others) using the PHP predefined variable, but it would be nice to work with something more dynamic and inclusive of all search engine user-agents.

Any suggestions on the best technique and/or approach here?

Thanks in advance!

penders

1:19 pm on Nov 12, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Hi besson3c, I assume you mean 'not' in your comment above :) ...

... and according to Google's FAQ it is best not to rely on Javascript to provide content you would like a search engine to be able to crawl.

besson3c

6:54 am on Nov 15, 2006 (gmt 0)

10+ Year Member



Yes.. not :)

Modifying content depending on user-agent to assist Google in indexing the site is fair game, right?

penders

12:26 am on Nov 20, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



I certainly see your point about dynamically modifying your content for search engines (based on user agent), if you are using JavaScript to generate your pages...

Thing is, based on this method, you could serve up any content based on what you *think* is a SE... this could include content that does not relate directly to your site, but would purely help to boost your SE ranking - afterall, that is what you are trying to do. If the SE's were to find this out, this *could* be judged as trying to artificially boost your ranking (IMHO), and could lose your ranking completely?! But how would the Search Engines know the difference?

What if they spidered your site using a perfectly normal user-agent and compared the results of the two?! - user-agents are easy to fake right?!

This is just a thought - I've not tried or even considered this method before - but would also be interested to hear from others on this matter.... fair game? Is it safe?

besson3c

12:59 am on Nov 20, 2006 (gmt 0)

10+ Year Member



That is the problem...

The User Agent check is somewhat of a hack, yet the only other way to generate non-Ajax content on the same page (without redirecting to another page) for search engines is to use the <noscript> and <script> tags to render content.

However, the problem with this approach is that Javascript is only executed upon initial page load, and not on Ajax invoked div tag reloads.

I'm still struggling to find a good, usable solution here...