In case it's any help to anyone, this is how I think I'll solve the
indexing problem.

My wife has a web site on which she sells various things, the
descriptions of which are stored in a database. I re-jigged her
website as a way to learn GWT. She was quite keen to have the GWT
version, but pretty peeved when I told her it would not be indexed by
Google, hence my desire to solve the indexing problem.

Currently, I have a cron job that re-creates a sitemap file each night
with URLs of the form

http://mysite/show_product.aspx?key=1234

etc, and the app is started from http://mysite/index.aspx.  (Backend
is currently using Mono). Using the GWT app, the cron job will now
create a new index.html file which looks like:

<html>
<body>
<script type="text/javascript">
        window.location = "http://mysite/MyGWTApp";;
</script>
<noscript>
       some welcome blurb
       <a href="http://mysite/TextOnlyServlet?1234";></a>
       .... insert URL for every product we want indexed...
</noscript>
</body>
</html>

and the sitemap will now contain URLs like

http://mysite/TextOnlyServlet?1234

etc. (These URLs probably don't need to be in index.html as the search
bot should read the sitemap anyway).

The TextOnlyServlet simply reads the product description from the
database and sends an unformatted HTML document back to the browser
which looks like:

<html>
<body>
<script type="text/javascript">
        window.location = "http://mysite/MyGWTApp#1234";;
</script>
<noscript>
       blurb for product 1234 read from database. Don't care about
format, just the words
</noscript>
</body>
</html>

So if a person clicks on a Google search result, which will be a URL
like http://mysite/TextOnlyServlet?1234, their browser will get the
HTML above and should redirect to the GWT app, which uses the correct
history token, and we're away. Certainly there is a small overhead in
the unnecessary text HTML sent down the line, but hopefully once in
the GWT app they will bookmark from within there, so next time around
they just get the GWT app.

I think this should work, and seems to me to be within the spirit of
the Google Webmaster guidelines.

Bryan
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to Google-Web-Toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to