SEO | BANS Duplicate Content & No 404 Pages

BANS Duplicate Content & No 404 Pages

June 27, 2008 By: Justin | 9 comments

So I just switched a domain over to BANS and noticed that dead URL’s return a 200 status code instead of a 404. It is hardcoded into BANS to return the main index page content with a status code of 200 if a page is not found. Well, this is a problem in terms of SEO.

The 200 status code tells Google the page exist and can be indexed. (and it will index it) If there are links pointing to a page on your site that should be 404, it will get indexed as a duplicate of the main page.

Standard methods of dealing with 404’s don’t work. A .htaccess entry won’t do the trick. You could manually disallow these pages in robot.txt, but that could be a horrible task if you have many pages. The site I switched over had 100 indexed pages before the switch. I now have about 80 duplicate pages indexed by Google with nothing but item listings and no content. All with same title. This is a big duplicate content problem.

A Solution

I found a cool hack from sonjay on the BANS forum, but it didn’t 100% solve my problem. I didn’t really like the solution 100%, and I’m not 100% happy with my solution either. But I played around and I’m getting the effect I want.

Go Into Your Index.php

I inserted this at line 563, right after

// End –>

</script>’;

and right before

if ($front->q != ” && $front->mainCat != ‘

INSERT THIS

Wordpress  messes up the code, so here it is in a txt file

Why the 301?

Well, I could have gone with the 404 and had the pages deindexed, but I had links pointing to some of those old pages. I wanted to keep the link juice, so I went with the 301 redirect to send all incoming traffic to the homepage.

I Make No Promises

I got that code off a forum. I make no promises and assume no responsibility for its use. I got it to work fine on my BANS, but I can’t be responsible for it messing up any of your sites. I just thought it was worth sharing.

Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • bodytext
  • del.icio.us
  • De.lirio.us
  • Fark
  • Reddit
  • description
  • Simpy
  • Slashdot
  • Sphinn
  • Spurl
  • StumbleUpon
  • Technorati
  • YahooMyWeb

Filed Under BANS, SEO |

Tagged With , , ,

Related Posts

Reasons .info BANS May Fail
A fair number of people have had issues with .info domains recently and .info BANS sites in particular. I recently wrote an article about how .info domains are different. Check
Dateless Sniper BANS Template
Another Free BANS Template from SEO Zombie. This time with a little twist. Over at Court’s Internet Marketing blog, he has blogged about a concept called keyword sniping. For the
.Info Domains Are Different
Not all TLD (Top Level Domain) are treated equal. Google treats .info domains differently than .com domains. This is especially true due to a recent GoDaddy domain sale. Google is
SEO BANS Template
SEO Zombie reworks the default BANS (Build A Niche Store) Template to improve its search engine optimization. This is a free BANS template that has a few SEO changes that
Internal Linking & Site Depth
SEO Lesson on how to improve your sites structure by linking internally and reducing your sites “depth”. They will improve improve Google’s ability to crawl your site while providing more

Comments

9 Comments »

Comment by anil
2008-07-01 05:19:09

Hi any one can help me,please check why my site was not indexed in google.

Comment by Justin
2008-07-03 01:11:47

Well, it not really showing links in Yahoo. I would work on link building. Plus, the dashes (-) in the domain name make it look a little spammy.

 
 
Comment by Scott Gostyla
2008-07-02 22:55:57

I was have a problem with this on one of my sites. Thanks so much for the little hack.

Comment by Justin
2008-07-03 01:11:56

np Scott

 
 
Comment by G
2008-07-05 02:33:19

Thanks a lot but I got error like below:

Warning: Cannot modify header information - headers already sent by (output started at /home/xxx/public_html/themes/layout-1-both/header.php:7) in /home/xxx/public_html/index.php on line 565

Warning: Cannot modify header information - headers already sent by (output started at /home/xxx/public_html/themes/layout-1-both/header.php:7) in /home/xxx/public_html/index.php on line 566

What happend?

Comment by Justin
2008-07-06 23:06:41

Seems like an error in your theme?

 
 
Comment by G
2008-07-11 04:29:04

I input in the first line of header.php and problem solved.

 
Comment by G
2008-07-11 04:30:22

Oh, wordpress deleted it. I input ob_start at the first line of header.php

 
Name (required)
E-mail (required - never shown publicly)
URI
Subscribe to comments via email
Your Comment (smaller size | larger size)
You may use <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> in your comment.

Trackback responses to this post