| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
how to 404 redirect from old root | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||||
|
|||||||||
how to 404 redirect from old root
we moved our site from www.corecases.com/store to the root - that's working fine, but apparently there are several links out there that still point to www.corecases.com/store/home.php
what is the best way to have any link that links to our /stoire folder to redirect to our current home page at www.corecases.com? am i right in thinking this could be addressed in our .htaccess file? should we have completely deleted the /store folder? i do have the DSEFU mod installed i looked for a while but did not see this specific topic addressed, so sorry if i missed it somewhere. TIA
__________________
X-Cart Gold 4.0.17 & 4.0.18 Linux Server Hands-On Hosting http://www.CoreCases.com - Ipod Cases http://www.InnovativeOutlet.com - Pet Plants and other cool stuff you need |
|||||||||
#2
|
|||||||
|
|||||||
put an htaccess in /store directory
Code:
__________________
X-Cart Gold 4.0.17 [unix] X-Cart Gold 4.0.18 [unix] |
|||||||
#3
|
|||||||||
|
|||||||||
ok, beautiful, that takes care of anyone going to store/home.php - thanks lionel -
is that one of those permanent redirects that won't harm SEO rankings, right? OK, next problem: since moving to the new store, i noticed that if someone clicks on an old search engine link (with the php url, like the one below), they get an error id=33 message - is there any way to just redirect them to the home page if they click on an expired/invalid link? i have totally redone my products with new productids and catids, so these items/categories do not exist anymore. thanks! Google search link: Code:
__________________
X-Cart Gold 4.0.17 & 4.0.18 Linux Server Hands-On Hosting http://www.CoreCases.com - Ipod Cases http://www.InnovativeOutlet.com - Pet Plants and other cool stuff you need |
|||||||||
#4
|
|||||||
|
|||||||
This has nothing to do with SEO
for broken links, if you do not want to display errors, put in the error documents in your htaccess. It's more elegant anyway Code:
and create the static pages, putting whatever you want in there. Me i put images of the categories. You can also put a sitemap.php instead of page.htm if you have that mod installed. Do a search on the net to see what those errors are and to create pages with proper wordings. Now for that error 33 it's a little more involved although simple. Go into include/func.php and just change that line in func.php to what you want, replacing the error_message.php?access_denied&id=33 with Quote:
Code:
__________________
X-Cart Gold 4.0.17 [unix] X-Cart Gold 4.0.18 [unix] |
|||||||
#5
|
|||||||||
|
|||||||||
lionel, the func.php mod worked great, you are the man!
i'll have to put in a litle more time on the custom redirects, but i agree, it's a much more elegant way to get the site visitor back on track. thanks! mike
__________________
X-Cart Gold 4.0.17 & 4.0.18 Linux Server Hands-On Hosting http://www.CoreCases.com - Ipod Cases http://www.InnovativeOutlet.com - Pet Plants and other cool stuff you need |
|||||||||
#6
|
|||||||
|
|||||||
Your original post is similair to a question i was wanting to ask.
Because we will be rebranding our site and with a different domain name. I'm wondering if its possible to do a blanket 301 redirect so that for example http://www.justhom.com/product.php?productid=366&cat=0&page=1 can become http://www.xyz.com/product.php?productid=366&cat=0&page=1<br /> <br /> with one line of code in .htacces... and variable.
__________________
x-cart 4.0.5 (live and heavily modded) Server: freebsd |
|||||||
#7
|
|||||||
|
|||||||
Quote:
I moved my site to the root and had the following line in my .htaccess file that redirected all my links that were out on the search engines to the proper page on the root. Essentially, it just removed the /xcart part from the link. www.mysite.com/xcart/product.php?productid=366&cat=0&page=1 was redirected to www.mysite.com/product.php?productid=366&cat=0&page=1. The .htaccess code for this redirect was as follows: Code:
Code:
__________________
X-Cart Pro 4.1.11 (Live) XRMA XAFF XAOM DSEFU Pro XGift Reg Firetank Feed Manager BCSE Shipping Calculator XcartMod Dynamic Images |
|||||||
|
|||
X-Cart forums © 2001-2020
|