Simple SEO For Web 2.0
Posted by: Greg Bulmash in Online Marketing And SEO, Techno ThoughtsBack in March, I did an experiment on whether Google indexes content inserted into your page with JavaScript. Weeks later, the results are conclusive... no. The words inserted into the test page via JavaScript were never indexed. Lots of pages talking about the odd words I used come up in searches for them, but the page I created doesn't come up in the Google results.
I recently saw a site advertising on Craigslist for SEO help. Their pages were almost 100% JavaScript and that meant that while Google indexed the page and saw their meta tags, almost all of their actual content didn't count. I did a "site:domain.com" search for them, found a page with what looked to be a unique phrase, then searched for the phrase. Nada, zilch, zero. Just more proof of my point.
"But, Web 2.0 is so cool," you say. "I can't remove all the neat JavaScripty geegaws and doodads from my pages. They'll be boring and flat." Well, you don't have to remove them. But you do need to do a little extra planning when creating your pages.
Basically, you need to ask yourself one question: "How would I display this page to someone who didn't have a JavaScript capable browser?" It doesn't necessarily have to be pretty or even that well organized, but it needs to have all the content the JavaScript would have inserted, just as as plain HTML instead. Why? Because Google's spider can read that HTML and the content in that HTML has rich keywordy goodness that can drive trafffic. It's going to strengthen your positioning for your chosen keywords and maybe even get you visitors via search terms you didn't predict.
So, when you're creating your page templates, go ahead and create the "gee whizbang" Web 2.0 version, but also create a "dull and ugly" Web 1.0 version. Then generate the final page that's delivered to the visitor using some PHP or some server-side scripting language that can fill in either template.
The nice thing about Google, Yahoo, and MSN is that they identify themselves in the user agent string they send to your server. They don't try to disguise themselves like some more shady spiders do. All you have to do is have a piece of PHP at the beginning of your page that uses the following logic: "If the user-agent string is for a known search engine spider, use the Web 1.0 template, otherwise use the Web 2.0 template."
Between query strings and server-side scripting, just about any content you can deliver via your cool Web 2.0 application can be delivered via its Web 1.0 counterpart. If your single web 2.0 URL has two states, represent it with two Web 1.0 URLs (i.e. grumpy.php?state=foo and grumpy.php?state=bar) using query strings and make sure that when it's in 2.0 mode, it can spot those query strings and adjust its content accordingly.
If you don't want to go to that length, go with something even simpler. Ignore the user-agent string and just plug that content in between <noscript></noscript> tags on every page for every visitor. It's more bandwidth intensive and increases the time it takes your pages to load, but visitors with JavaScript enabled won't see it, and those without JavaScript won't be left in the dark, staring at a blank or mostly blank page.
The one caution on the <noscript> method is that I've seen people using it for black-hat SEO. They take their huge batch of spamdexing keywords, and instead of trying to hide them by shrinking them down really small and/or making them the same color as their page background, they put them between <noscript> tags. That way they're not visible to anyone with a JavaScript enabled browser unless they view the page source, but the search engine spiders see them. So be careful in how you use that method.
Maybe at some future point, the Web spiders will scan your javascript for keywords and content, or maybe even execute it and then index the interactive page in its various states. But for now, they don't, and if you want to get all that lovely free traffic the search engines send, you need to accomodate them by offering them versions of your pages they can read.

Entries (RSS)