Webmaster Forum


Go Back   Webmaster Forum > Marketing Forums > Google Forum

Google Forum Discuss Google related issues.


Reply
 
LinkBack Thread Tools Display Modes
Share |
  #1 (permalink)  
Old 05-14-2012, 06:34 AM
nathan.joshua's Avatar
Contributing Member
 
Join Date: 03-31-12
Location: Dorset
Posts: 123
iTrader: 0 / 0%
Question Additional code added to my home page URL

I just finished another website and I noticed something strange when Google WMT dashboard finally picked up my website.

In the Optimization > HTML Improvements tab, it says "Duplicate title tags x 2". homepage.com/ and a page called hompage.com/?p=1&cpage=1.

When I go to homepage.com/?p=1&cpage=1 it is the same as my homepage.com.

This means Google is seeing 2 pages that are exactly the same on my website.

I tried redirecting hompage.com/?p=1&cpage=1 to hompage.com/ but it created a redirect loop.


Has anyone had this problem before?
Is there a way to solve it?
Does it affect my Google rankings?
__________________
Freelance Web Designer
Follow on Twitter for my weekly blog post.
 
Reply With Quote
  #2 (permalink)  
Old 05-14-2012, 08:06 AM
Tiggerito's Avatar
v7n Mentor
 
Join Date: 09-12-10
Location: Adelaide, South Australia
Posts: 298
iTrader: 0 / 0%
The main thing you should do is find where the link is to the alternate home page and change it to your true home page.

The redirect will then help Google remove it from the index.

How are you doing the redirect?
__________________
By Tony McCreath, owner of Web Site Advantage
Do not try this at home!
 
Reply With Quote
  #3 (permalink)  
Old 05-14-2012, 08:36 AM
nathan.joshua's Avatar
Contributing Member
 
Join Date: 03-31-12
Location: Dorset
Posts: 123
iTrader: 0 / 0%
Quote:
Originally Posted by Tiggerito View Post
The main thing you should do is find where the link is to the alternate home page and change it to your true home page.
I searched my entire website in Notepad++ and couldn't find any reference to ?p=1&cpage=1.

Quote:
Originally Posted by Tiggerito View Post
The redirect will then help Google remove it from the index.
It seems Google now thinks homepage.com/?p=1&cpage=1 is my home page

Quote:
Originally Posted by Tiggerito View Post
How are you doing the redirect?
cPanel redirect feature. However, when I try to redirect it is telling me it will create a redirect loop and does not add it to my .htaccess.

This is very strange, and I've yet to find any reference to this behaviour on Google search.(the only page referencing to "?p=1&cpage=1" is this thread).

If I search for mydomain.com/?p=1&cpage=1 on Google I can see it.

Does anyone know what ?p=1&cpage=1 actually does? Maybe we can go from there.

The only thing different I did with this domain is add a redirect for homepage.com/index.php -> homepage.com. Could this be causing it?
__________________
Freelance Web Designer
Follow on Twitter for my weekly blog post.

Last edited by nathan.joshua; 05-14-2012 at 08:56 AM. Reason: additional info
 
Reply With Quote
  #4 (permalink)  
Old 05-14-2012, 09:35 AM
nathan.joshua's Avatar
Contributing Member
 
Join Date: 03-31-12
Location: Dorset
Posts: 123
iTrader: 0 / 0%
Quote:
Originally Posted by nathan.joshua View Post
I searched my entire website in Notepad++ and couldn't find any reference to ?p=1&cpage=1.


It seems Google now thinks homepage.com/?p=1&cpage=1 is my home page


cPanel redirect feature. However, when I try to redirect it is telling me it will create a redirect loop and does not add it to my .htaccess.

This is very strange, and I've yet to find any reference to this behaviour on Google search.(the only page referencing to "?p=1&cpage=1" is this thread).

If I search for mydomain.com/?p=1&cpage=1 on Google I can see it.

Does anyone know what ?p=1&cpage=1 actually does? Maybe we can go from there.

The only thing different I did with this domain is add a redirect for homepage.com/index.php -> homepage.com. Could this be causing it?
Ok I found a solution for this:

Add this to your .htaccess:
Code:
RewriteCond %{QUERY_STRING} !="" RewriteRule (.*)$ http://www.mydomain.com/%1? [R=301,L]
What this does: All query strings from the homepage, like homepage.com/?p=1 will auto redirect to your home page.

Still trying to figure out how this happened in the first place .. who cares, problem solved
__________________
Freelance Web Designer
Follow on Twitter for my weekly blog post.
 
Reply With Quote
  #5 (permalink)  
Old 05-14-2012, 12:33 PM
jjmcd82's Avatar
Contributing Member
 
Join Date: 04-27-12
Location: North Carolina
Posts: 52
iTrader: 1 / 100%
Quote:
Originally Posted by nathan.joshua View Post
Add this to your .htaccess:
Code:
RewriteCond %{QUERY_STRING} !="" RewriteRule (.*)$ http://www.mydomain.com/%1? [R=301,L]
What this does: All query strings from the homepage, like homepage.com/?p=1 will auto redirect to your home page.

Still trying to figure out how this happened in the first place .. who cares, problem solved
This is really, really awesome! I have no idea where Google comes up with these queries strings, but it has indexed a ton as duplicate content and now I can finally get rid of 'em!
__________________
WebsiteBuilding.biz - PM if you're interested in guest-posting
Need hosting? Get a custom plan
 
Reply With Quote
  #6 (permalink)  
Old 05-14-2012, 10:34 PM
Tiggerito's Avatar
v7n Mentor
 
Join Date: 09-12-10
Location: Adelaide, South Australia
Posts: 298
iTrader: 0 / 0%
Quote:
Originally Posted by nathan.joshua View Post
Ok I found a solution for this:

Add this to your .htaccess:
Code:
RewriteCond %{QUERY_STRING} !="" RewriteRule (.*)$ http://www.mydomain.com/%1? [R=301,L]
What this does: All query strings from the homepage, like homepage.com/?p=1 will auto redirect to your home page.

Still trying to figure out how this happened in the first place .. who cares, problem solved
I'd be vary careful with that solution. It's like using a sledge hammer to fix a ding. You will most likely break a lot of other things. e.g. campaign tracking code, AdWords landing pages, internal paging, social links with tracking code...

What was the original redirect code you tried? Let's try and fix it. Show us any other rewrites/redirects you also have as this may give light into why you caused a redirect loop.

It's not just your own website that can cause Google to index funny pages:

Any previous versions of your website may have used that page. Google has a long memory.

Check your xml sitemap generate and rss feed. They can also tell Google lies.

Other website may link to that page. I see a lot of random indexed pages on my website due to crappy domain info websites with buggy link generators.
__________________
By Tony McCreath, owner of Web Site Advantage
Do not try this at home!
 
Reply With Quote
  #7 (permalink)  
Old 05-15-2012, 03:16 PM
nathan.joshua's Avatar
Contributing Member
 
Join Date: 03-31-12
Location: Dorset
Posts: 123
iTrader: 0 / 0%
Quote:
Originally Posted by Tiggerito View Post
I'd be vary careful with that solution. It's like using a sledge hammer to fix a ding. You will most likely break a lot of other things. e.g. campaign tracking code, AdWords landing pages, internal paging, social links with tracking code...

What was the original redirect code you tried? Let's try and fix it. Show us any other rewrites/redirects you also have as this may give light into why you caused a redirect loop.

It's not just your own website that can cause Google to index funny pages:

Any previous versions of your website may have used that page. Google has a long memory.

Check your xml sitemap generate and rss feed. They can also tell Google lies.

Other website may link to that page. I see a lot of random indexed pages on my website due to crappy domain info websites with buggy link generators.
**You are absolutely right, for e-commerce websites, some CMS websites and websites that use "campaign tracking code, AdWords landing pages, internal paging, social links with tracking code" this redirect code will cause more problems than it solves.

However, my website does not use the above so it works fine.

For anyone using this code: Make sure your website does not use the above**.

What we need is an SEO to tell us if query stringed pages have a negative affect on the real pages. It's logical that it would in my experience.
__________________
Freelance Web Designer
Follow on Twitter for my weekly blog post.
 
Reply With Quote
  #8 (permalink)  
Old 05-15-2012, 06:25 PM
Tiggerito's Avatar
v7n Mentor
 
Join Date: 09-12-10
Location: Adelaide, South Australia
Posts: 298
iTrader: 0 / 0%
You might not use it, but others who link to your website may.

I had to reverse engineer an issue which was down to me using a URL shortener that automatically added campaign tracking code (dilvr.it). My use of it in tweets to a domain which poorly handed query string parameters were causing the links to fail.

Luckily, the recipient of the links raised the issue that my tweets were broken and I worked out it was their website. For the reason of that one websites problems I disabled all tracking.

If there is one case like this, there will be others.
__________________
By Tony McCreath, owner of Web Site Advantage
Do not try this at home!
 
Reply With Quote
  #9 (permalink)  
Old 05-17-2012, 07:03 AM
nathan.joshua's Avatar
Contributing Member
 
Join Date: 03-31-12
Location: Dorset
Posts: 123
iTrader: 0 / 0%
Quote:
Originally Posted by Tiggerito View Post
You might not use it, but others who link to your website may.

I had to reverse engineer an issue which was down to me using a URL shortener that automatically added campaign tracking code (dilvr.it). My use of it in tweets to a domain which poorly handed query string parameters were causing the links to fail.

Luckily, the recipient of the links raised the issue that my tweets were broken and I worked out it was their website. For the reason of that one websites problems I disabled all tracking.

If there is one case like this, there will be others.
Maybe there is a more.. subtle way to do this with robots.txt:

Code:
Disallow: /specificQuery
Do you think this would work? I've yet to try it as it could possibly disallow the homepage.
__________________
Freelance Web Designer
Follow on Twitter for my weekly blog post.
 
Reply With Quote
  #10 (permalink)  
Old 05-17-2012, 07:59 AM
Tiggerito's Avatar
v7n Mentor
 
Join Date: 09-12-10
Location: Adelaide, South Australia
Posts: 298
iTrader: 0 / 0%
I think it's better you do nothing in favour of these ideas.

Google is only giving you automated hints. You don't want to take these and do strange things (as per your suggestions) to damage your website.

Focus on what matters...content

and resolve canonical issues if you have the resources.
__________________
By Tony McCreath, owner of Web Site Advantage
Do not try this at home!
 
Reply With Quote
Go Back   Webmaster Forum > Marketing Forums > Google Forum

Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Easy way to get additional likes for your Facebook Page CodCom Social Network Marketing 10 06-27-2011 10:23 PM
code just like google home page Johnaranger Coding Forum 13 08-28-2010 01:23 PM
301 code for home page links nigelaxis Coding Forum 3 06-21-2006 10:30 AM


V7N Network
Get exposure! V7N I Love Photography V7N SEO Blog V7N Directory


All times are GMT -7. The time now is 02:25 PM.
Powered by vBulletin
Copyright © 2000-2013 Jelsoft Enterprises Limited.
Copyright © 2003 - 2013 Escalate Media LP




Search Engine Optimization by vBSEO 3.6.0 RC 2 ©2011, Crawlability, Inc.