Question

I am developing a website using GAE Python. It has only a few html pages which are available using Django template. The website allows you to search for bus tickets by selecting country, state, city, date, type of bus and other parameters. I use AJAX POST to send all these criteria to the server side(python). The server side performs a NDB query and returns the available bus operators with details for the selected date. This information is returned as JSON data. After the user clicks on a bus operator, I open a popup on the same page and retrieve and display more details using AJAX POST again in the same way.
The URL at the top of my page remains throughout:

http://localhost:8080/search  

[right now the website is not complete and so not online, therefore "localhost"]

Problem: I want to make all the bus operators search results on my website google searchable (actually, searchable by any search engine if possible). In other words, I want Google to somehow index my dynamic search result page so that when people search for bus on google, my website and my search page should come in the google search results

I tried Google search and found the following but could not understand the solution. I did not understand stuff about hash fragment since I have used AJAX POST query string only which do not come in URL like hash fragments.

https://developers.google.com/webmasters/ajax-crawling/docs/specification
http://coding.smashingmagazine.com/2011/09/27/searchable-dynamic-content-with-ajax-crawling/
How to make google search dynamic pages of my site Hash tag, query string, and Ajaxified search results

I am a novice here and would appreciate any help

Was it helpful?

Solution

Search engines will index your results only if they find links to them. In this case, you want these links to be SEO-friendly. There are plenty of articles on how this can be accomplished.

Simply adding a hashtag to your URL after you display the results is easy, but it will not achieve anything.

One solution is to create a site map file and submit it to Google. You can list the most popular (or all, if you don't have too many) results from your database in this site map. In this case you need links in this site map to read like:

myDomain.com/search/?city=London

or

myDomain.com/search/#London

In both cases, your servlet or your app should be able to process this link when a user hits it directly, and display the correct results to a user.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top