Wordpress Transposh Plugin Problem

sviedinys

Power Member
Joined
Apr 18, 2010
Messages
525
Reaction score
75
I was getting pretty nice traffic with this auto translate plugin until that update/refresh came.
I removed this plugin, but google bot still crawls my pages with languages like:

?lang=lo ?lang=th ?lang=ru

Should I just wait or reset somehow, why bot still crawls like this if plugin removed?
 
When i check mysite.com/sitemap.xml everything looks good there, all urls correct.
Yesterday I resubmited sitemap in webmaster tools.
 
I recently saw something similar with google still indexing and crawling some urls it has once discovered and that do not exist anymore on some of my blogs.

I first I thought it was simply because these URLs were redirecting to some content on my site anyway, but google still has some URLs indexed on a subdomain of mine that don't even exist anymore (I deleted this subdomain several months ago!)

So it seems that for some reason google keeps URLs in its index for a very long time, and keeps crawling them even if there's nothing to see there.

Anyway here's what I did:
- I used scrapebox to scrap all of the URLs of my domain that are still in google's index.
- Then I took all of those URLs that don't exist anymore on my site and set 301 redirects either to some relevant posts/pages or simply to my blog's homepage.

With proper 301 redirects hopefully google will update its index next time it crawls these urls.
 
Thats covering every angle..very nice !

I recently saw something similar with google still indexing and crawling some urls it has once discovered and that do not exist anymore on some of my blogs.

I first I thought it was simply because these URLs were redirecting to some content on my site anyway, but google still has some URLs indexed on a subdomain of mine that don't even exist anymore (I deleted this subdomain several months ago!)

So it seems that for some reason google keeps URLs in its index for a very long time, and keeps crawling them even if there's nothing to see there.

Anyway here's what I did:
- I used scrapebox to scrap all of the URLs of my domain that are still in google's index.
- Then I took all of those URLs that don't exist anymore on my site and set 301 redirects either to some relevant posts/pages or simply to my blog's homepage.

With proper 301 redirects hopefully google will update its index next time it crawls these urls.
 
No, the problem is that its the same url, not different, its appearing like this www.domain.com/page/?lang=th (all languages) I cant redirect anything here, its just a plugin of WP which is removed.

ahrefs shows thousands of "Warnings" because of to much URLs, I think thats why my traffic dropped badly, but now I just removed this plugin.



I recently saw something similar with google still indexing and crawling some urls it has once discovered and that do not exist anymore on some of my blogs.

I first I thought it was simply because these URLs were redirecting to some content on my site anyway, but google still has some URLs indexed on a subdomain of mine that don't even exist anymore (I deleted this subdomain several months ago!)

So it seems that for some reason google keeps URLs in its index for a very long time, and keeps crawling them even if there's nothing to see there.

Anyway here's what I did:
- I used scrapebox to scrap all of the URLs of my domain that are still in google's index.
- Then I took all of those URLs that don't exist anymore on my site and set 301 redirects either to some relevant posts/pages or simply to my blog's homepage.

With proper 301 redirects hopefully google will update its index next time it crawls these urls.
 
No, the problem is that its the same url, not different, its appearing like this www.domain.com/page/?lang=th (all languages) I cant redirect anything here, its just a plugin of WP which is removed.

The same url with a different attribute is just like a different url. And you can simply rewrite/redirect it as well.

In this specific case, you can simply catch and remove the "lang" attribute in any url of your site, which will solve your problem.
 
But how I should remove/block it? It was appearing auto with that plugin.

The same url with a different attribute is just like a different url. And you can simply rewrite/redirect it as well.

In this specific case, you can simply catch and remove the "lang" attribute in any url of your site, which will solve your problem.
 
But how I should remove/block it? It was appearing auto with that plugin.

Here's a code for you, what it does is catch the "lang" attribute (if it is set in the url), and if it exists then redirect to the same url without this attribute.

It is basically just like setting automatic 301 redirects to point any url like "yoursite.com/whatever/?lang=th" to "yoursite.com/whatever/".

Copy/Paste this in your theme's functions.php and you'll be done.

PHP:
function remove_lang_attr($wp) {
    // Get the lang attribute from the url
    $lang = $_GET['lang'];
    // if there is a lang attribute in the url...
    if ("" != $lang) {
        // rewrite the URL without the lang attribute
		$url = site_url().remove_query_arg( 'lang' );
		// redirect to the rewritten url
    	wp_redirect($url);
    }
}
add_action('parse_request', 'remove_lang_attr');

Then you will just need to wait for google to update it's index (which will happen as soon as it re-crawls these url and see that they are now redirected).
Note: if someday you want to reactivate this plugin, don't forget to remove this code to re-allow the lang attribute!
 
Thanks!

Here's a code for you, what it does is catch the "lang" attribute (if it is set in the url), and if it exists then redirect to the same url without this attribute.

It is basically just like setting automatic 301 redirects to point any url like "yoursite.com/whatever/?lang=th" to "yoursite.com/whatever/".

Copy/Paste this in your theme's functions.php and you'll be done.

PHP:
function remove_lang_attr($wp) {
    // Get the lang attribute from the url
    $lang = $_GET['lang'];
    // if there is a lang attribute in the url...
    if ("" != $lang) {
        // rewrite the URL without the lang attribute
        $url = site_url().remove_query_arg( 'lang' );
        // redirect to the rewritten url
        wp_redirect($url);
    }
}
add_action('parse_request', 'remove_lang_attr');

Then you will just need to wait for google to update it's index (which will happen as soon as it re-crawls these url and see that they are now redirected).
Note: if someday you want to reactivate this plugin, don't forget to remove this code to re-allow the lang attribute!
 
But actually it doesnt helping, with each day im getting more and more warnings and errors in ahref.

That plugin just killed that site, over 30k warnings and all caused by that plugin. Mostly because of "to many pages". Now only the time solve it, need to wait and see what happens.

Here's a code for you, what it does is catch the "lang" attribute (if it is set in the url), and if it exists then redirect to the same url without this attribute.

It is basically just like setting automatic 301 redirects to point any url like "yoursite.com/whatever/?lang=th" to "yoursite.com/whatever/".

Copy/Paste this in your theme's functions.php and you'll be done.

PHP:
function remove_lang_attr($wp) {
    // Get the lang attribute from the url
    $lang = $_GET['lang'];
    // if there is a lang attribute in the url...
    if ("" != $lang) {
        // rewrite the URL without the lang attribute
        $url = site_url().remove_query_arg( 'lang' );
        // redirect to the rewritten url
        wp_redirect($url);
    }
}
add_action('parse_request', 'remove_lang_attr');

Then you will just need to wait for google to update it's index (which will happen as soon as it re-crawls these url and see that they are now redirected).
Note: if someday you want to reactivate this plugin, don't forget to remove this code to re-allow the lang attribute!
 
Last edited:
So is there really any safe way to use this plugin? I installed this and started reading posts about it here and got a little freaked out and deactivated it. In the options there is a way to make the URLS searchable, unchecking this and then visiting a page I didn't see any "noindex" tag so that didn't seem to do much. There was also a way to set custom URLS. Instead of "/?lang=fr" you would have "/fr/pagename/". Any thoughts on this? Seems like a cool plugin but I'm not risking it.
 
Back
Top