• Plugin Author helenthomaswp

    (@helenthomaswp)


    If you need your traffic stats to be more accurate, you should use the Automatic Traffic Filter on the Widget. However, the internet is full of spiders, crawlers and all kind of robots not authenticating themselves as machines. Furthermore, it is very difficult to verify the signature of each and every robot visiting your blog… But there is a pretty good solution to this. I cannot access the root directory of your blog through WordPress install API, so you will have to do the following things by yourself:

    1. Create a robots.php file on the root directory of your blog: ie public_html/your-blog/
    Paste the following code in it:

    <?php
    session_start();
    $_SESSION['wtcrobot'] = 1;
    echo file_get_contents('robots.txt');
    exit;
    ?>

    1. Open .htaccess file in the same directory and paste this in it:

    RewriteRule robots\.txt robots.php

    1. Make sure you have the ‘RewriteEngine On’ clause in place…

    1. Make sure you have a robots.txt file, even an empty one, on the root directory

    Done! Most of the robots will be filtered out by TSW.

    http://wordpress.org/extend/plugins/traffic-stats-widget/

Viewing 1 replies (of 1 total)
  • I have several questions:
    1) Please elaborate on the ‘RewriteEngine On’ clause. What file does that go in and what is the syntax?
    2) The backslash looks oddly placed to me. Please confirm that it is in the correct location.
    3) I have a forum on my domain and I am using the robots.txt file. If I am reading these commands right the file will be overwritten. Please confirm that the file will be left as is.

    Forgive my ignorance but I am just starting to use WordPress and I want to make sure that I get it right. With my limited understanding you instructions seem incomplete.

    My WP

Viewing 1 replies (of 1 total)
  • The topic ‘Filtering’ is closed to new replies.