go top


  • Colection of 65 PHP scripts for $4.29 each

Get 65 PHP scripts in a bundle for $4.29 each!

View Offer

Google and AJAX crawling

by Dimitar Ivanov /  Useful Resources

We are often asked by clients how well our scripts are optimized for search engines. With scripts that use PHP include this is not an issue as all the content is printed directly on the web page. Our PHP Blog script, for example, can be integrated into your website with a PHP include code. It prints all the content within the HTML code of the respective page - just view the source of your web page, and you will see the actual blog post text. So, when Google crawls your website, it will see the content and index it. Using the built-in SEO module, we can make each blog post URL unique (such as "blog-post-title.html").


Website and the inspect elements section comparison


Scripts that use JavaScript integration, however, work a bit differently. Instead of printing the actual content within the page HTML code, there is only a piece of JavaScript code. Let's see our PHP Shopping Cart script, for instance. If you check the source code of the web page, you will only see a piece of JS code like this:

<script type="text/javascript" src="index.php?controller=pjFront&action=pjActionLoad"></script>

Ecommerce website and the inspect elements section comparison
Furthermore, the URL for the web page is like this:


You can see that the primary page file name is "preview.php" and it is always like that, no matter what menu on the shopping cart you navigate to. What changes is the parameter "passed". So, the script uses AJAX calls to show the content you request - product details, shopping cart etc. Back in the past, such AJAX-served content was not indexed, or at least not correctly indexed, by Google. Last year, however, Google announced that they crawl such content now and there is no reason for you to worry about your search engine optimization of scripts like ours using JavaScript integration and AJAX calls. Learn more about this topic on Google's official blog!

Share on:

0 Comments to "Google and AJAX crawling "

Add your comment


    Please, be polite and helpful and do not spam or offend others! We promise you will be treated the same way!

    Log in to your account to post your comments. If you still haven't joined our community yet, you can create your FREE account now!

    Posting tip:
    If you use code in your comments, please put it in these tags [php], [sql], [css], [js] PHP code example: [php] echo date("Y-m-d"); [/php]

    Thank you,
    PHPJabbers Team