E-Commerce: Random Cart ID Redirects
-
Hi All,
I'm having an ecommerce cart issue. Basically, each time a purchase is made, the cart pops up with a unique id (eg www.mysite.com/cart.php?action=add&product_id=3728), This is being caught by MOZ scans as an individual page in some instances.
Could I simply add Disallow: /cart.php to my robots.txt to nix this issue? In theory it should keep all subsequent query strings from being indexed, right?
Thanks!
-
I'm using Interspire's shopping cart system with a few modifications. There's absolutely no official support for it at this point, so I appreciate your help.
The cart is a standalone php page, so I think that just blocking that off should be sufficient.
Thanks!
-
No problem. What platform do you use, because you can include what CleverPhD said as well, it really just depends on how the headers of the template are generated. I am not familiar with a platform that uses directories for the cart pages, but I am sure that some exist. One thing to watch out for if you try to no follow a whole directory is, some carts put all of their secured (ssl) pages in the same place. This could include the contact page, which you want to leave index able. If you are not familiar with coding in the platform, I would avoid it, because if you got the conditional code wrong, you could de-index a portion of your site accidentally.
-
Thanks, Lesley. I've just added the cart page to the disallow list.
-
I would add, you want to also no follow, noindex all links to any of your shopping cart pages. Ideally, if you have your cart pages in a given folder, you can disallow the whole folder and take care of things as a group.
-
Generally you always disallow the cart page in e-commerce sites. The reason being is that some spiders like baidu, will make fake shopping carts when spidering your site. If you keep track of your abandoned cart rate, this will wreak havoc on your stats.
When you disallow the cart.php, it will keep the whole page from being indexed, which ideally is not a bad thing. More than likely the way your cart works is it uses ajax to post the product to that page silently to add it to the cart. But at the same time if you go to site.com/cart.php it will more than likely take you to the cart screen. There really is no inherit value in having that page indexed by search engines. If people are coming to that page, it will also skew your numbers when you are trying to figure why people are dropping out of the checkout process.
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Robots txt. in page with 301 redirect
We currently have a a series of help pages that we would like to disallow from our robots txt. The thing is that these help pages are located in our old website, which now has a 301 redirect to current site. Which is the proper way to go around? 1- Add the pages we want to disallow to the robots.txt of the new website? 2- Break the redirect momentarily and add the pages to the robots.txt of the old one? Thanks
Technical SEO | | Kilgray0 -
Remove a page after redirection
Hi, I had page eg. www.example.com/page1 and I redirect 302 it to > www.example.com/page2 After that I fatch this page (page2) with GSC and this page was index in serp. Can I remove this old redirect page > www.example.com/page1 now? Will this remove harm my page?
Technical SEO | | Tormar0 -
301 Redirect
Hello Moz Community, I have a question regarding 301 redirecting a new domain that contains keywords relevant to my website. However, I do NOT want to change my current domain. My main question is, by just redirecting this new domain to my current website, will those keywords in the new domain help with ranking in anyway? Thanks in advance for any help!
Technical SEO | | WyzeOwl0 -
60% Internal Redirects
A new client I am working with has a site with over 9,000 internal 301 redirects. These are as a result of old links not being updated and the number of internal 301 redirects far outweighs the number of 'correct' links on the site. My personal opinion is that creates the risk of crawl errors/issues and whilst a 301 redirect is correct in this case, it does not negate the need to update internal links. The problem I have is that when I explain this to the client, they reply with an Matt Cutts video from 2008 that talks about 301 redirects being correct for site migrations. Even though the video is not entirely relevant to the point, I can not get the client to move from his position. Ideally, what I am looking for help with is the following: Am I right in my position that having this many redirects is a potential issue and that internal links should be updated? Does anyone know of any articles from 'notable/reputable' sources that I can use in order to support my position? Thanks in advance for your help.
Technical SEO | | MattHopkins0 -
301 redirect + new website copy
Hi There, We are currently redeveloping our website and we're rewriting and optimising our many of our service pages. I think I may already know the answer but should we apply 301 redirects from our old services pages to the new versions? The content subject matter will be the same on the new versions, they will just be completely reworded. I would be interested to hear your views. Thanks, Stu
Technical SEO | | Stuart260 -
CPanel Redirects: Know How Needed
I have ran into something I have not ran into in the past. cpanel, setting a 301 redirect. --Drop down domain choice ----- / ---- ?attachment_id=539 http://ipromotis.com (Only box marked is redirect with or without www) Produces 301 Redirect http://ipromotis.com to http://ipromotis.com
Technical SEO | | yeagerd0 -
302 Redirect from HTTP to HTTPS
Hi Guys One of our client's website is having 586 linking unique domains to http://www.XYZ.com.au (to home page only). They have migrated their site to https://www.XYZ.com.au so all of their site pages are on HTTPS now instead of HTTP. The HTTP version of the home page is 302 redirected to HTTPS therefore we think they are not getting all the link juice of 586 linking domains and would like to recommend to change their 302 to 301. However we have not seen any ranking drop due to this migration and redirect in place. The new HTTPS site/redirect is live from last 2 months now. So not sure its worth recommending 301 or not? Does this mean Google is picking up this 302 redirect as normal and attributing all link value to HTTPS version? Please can anyone share their thoughts on recent Google interpretation of 302 from HTTP to HTTPS? Thanks
Technical SEO | | JamesDixon700 -
Redirection Plugin and Regular Expressions
I am using Wordpress and the Redirection plugin. I have recently launched a new site and while it was in development, a lot of broken pages were created and indexed. These are terminating in 404s. I am looking to redirect all traffic from: /replay/postname/ to the homepage. When I use this regular expression: Source: /replay/* Target: / it removes the /replay/ but leaves the postname. Any idea how I could redirect all traffic inside of /replay/ to the homepage? Thanks a bunch, Josh
Technical SEO | | dreadmichael0