Possible Duplicate:
Does Google crawl AJAX content?
So I have a forum - the link is of the following URL format COURSE PAGE - http://www.example.com/course/course-feed/course_id/1
Now this page has a bunch of questions and each question is a link which upon clicking takes you the to question detailed page which shows all the answers to that question -
example format of the detailed question page url QUESTION PAGE - http://www.example.com/course/question-feed/course_question_id/636
So if I have 5000 questions, I have 5000 question pages with answers.
Now my question is the COURSE PAGE, obviously does not display all the 5000 questions. Rather it display 50 question links and has a "MORE" button at the bottom.
When the user clicks "MORE" - the next 50 questions are fetched through a JQUERY call and displayed below. Now when this operation happens - the URL obviously does not change.
When I recently looked at how many of pages got indexed in Google - its only the first 50 question pages because the indexed COURSE PAGE shows only 50 question links.
My question is how to get the crawler to go through all the "MORE" links and index all the 5000 pages.
Short answer: It doesn't.
Long answer: If your content is only accessable via javascript calls, and with no fallbacks, Google is not indexing it. Without seeing the page, I would presume that the link normally links to something along the lines of http://example.com/questions.php?page=2
, which is processed by the back end. You could then override the link with some JQuery:
<a href="/questions.php?page=2" class='nextPage'>
<script>
$('a.nextPage').click(function(){
e.preventDefault();
$.ajax(/*etc*/)
})
</script>
This is just yet another in a long list of reasons to always degrade gracefully.