Page 4 of 4 FirstFirst ... 234
Results 31 to 37 of 37
  1. #31
    Join Date
    Jun 2009
    Location
    Kent, UK
    Posts
    347
    Plugin Contributions
    5

    Default Re: I've deleted products. How do I redirect customers to new ones? or to search inst

    one more very quick question (sorry!!)

    i also need to do this for some image folders which i uploaded as "/images/medium/products/gift cards/" rather than "/images/medium/products/gift_cards/" (had a space instead of underscore

    would this be the same method or different?

  2. #32
    Join Date
    Nov 2007
    Location
    Woodbine, Georgia, United States
    Posts
    4,019
    Plugin Contributions
    61

    Default Re: I've deleted products. How do I redirect customers to new ones? or to search inst

    That you must really fix... cannot redirect it
    PRO-Webs, Inc. :: Recent Zen Cart Projects :: Zen Cart SEO – 12 Steps to Success
    **I answer questions in the forum, private messages are NOT answered. You are welcome to contact us via our website for professional engagements.

  3. #33
    Join Date
    Jun 2009
    Location
    Kent, UK
    Posts
    347
    Plugin Contributions
    5

    Default Re: I've deleted products. How do I redirect customers to new ones? or to search inst

    yes sorry, i have fixed the folder name on my server and products etc but i am still getting requests for those images and a 404 response, i meant in terms of redirecting them to the correct place rather than them searching for a broken url

  4. #34
    Join Date
    Jul 2010
    Posts
    15
    Plugin Contributions
    0

    Idea or Suggestion Re: I've deleted products. How do I redirect customers to new ones? or to search inst

    Hi

    Can someone please tell me how to put mulitple product ids in Rewrite condition.

    RewriteCond %{QUERY_STRING} products_id=537
    RewriteRule (.*) http://www.livvylou.co.uk/$1? [R=301,L]

    I am able to get this working for a single product id but dont know how to put multiple product ids in condition.

    please help me in getting out of this.
    thanks.

  5. #35
    Join Date
    Nov 2007
    Location
    Woodbine, Georgia, United States
    Posts
    4,019
    Plugin Contributions
    61

    Default Re: I've deleted products. How do I redirect customers to new ones? or to search inst

    This part is the query string

    products_id=537

    So for example changing it to

    products_id=

    would redirect all product pages.

    You must identify a common string that all of the pages you want to redirect share.

    ~Melanie
    PRO-Webs, Inc. :: Recent Zen Cart Projects :: Zen Cart SEO – 12 Steps to Success
    **I answer questions in the forum, private messages are NOT answered. You are welcome to contact us via our website for professional engagements.

  6. #36
    Join Date
    Oct 2008
    Location
    Lakewood Ny
    Posts
    26
    Plugin Contributions
    0

    help question Re: I've deleted products. How do I redirect customers to new ones? or to search inst

    Quote Originally Posted by mprough View Post
    7thVeil, I have edited your code and have some other relevant information and technique regarding this issue here http://pro-webs.net/blog/2010/03/21/...tock-products/

    I have always forced a permanent redirect by hand (ultimate control), but I certainly understand the need for a more large scale dynamic solution. So I edited your code to achieve this.

    Cheers,

    Melanie
    Melanie
    I know this is an old post but I am having a similar issue with Sorry, the product was not found. on pages products have been roved I am using:
    Zen Cart 1.3.9h
    Patch: 1::
    Database Patch Level: 1.3.9h
    and the solution you gave didn't work in this version. Do you have any suggestions on how to fix this is the version in have mentioned?
    Any help would be greatly appreciated.

    This is what I am referring to:

    How about a more dynamic solution?

    In the forum thread we noted earlier, Zenner 7thVeil suggested using a php redirect to move these pages to the category page for their original location. This is an excellent technique for a dynamic solution. The code change supplied by 7thVeil, was very smart, but incomplete as it was returning a 302 in the header. We definitely do not want to return a 302, as this is a temporary redirect, but a permanent headache for your SEO campaign.

    So I tweaked his alteration for the following which will send disabled and deleted products to their category page with a permanent 301 redirect. If no category exists they are sent to the product not found page.

    In /includes/modules/pages/product_info/main_template_vars.php around line 31 find:

    if ( $res->fields['total'] < 1 ) {

    Just below this you will see

    $tpl_page_body = '/tpl_product_info_noproduct.php';

    Replace this line with

    $requeststring = (isset($_GET['cPath']))?'&cPath='. (int)$_GET['cPath']:'';
    header( "HTTP/1.1 301 Moved Permanently" );
    header('location:index.php?main_page=index'.$requeststring);

    Remember this is really a very dynamic solution and you are giving up the ultimate control over where this product page url should be sent. There is also the possibility, if you are using a SEO rewrite module, that this tweak will result in a double redirect. This is not a good situation, so if you apply this and the header for the pages is sending a double redirect, or worse, a loop... then this solution is not for you.
    Gary
    Last edited by deziner76hd; 14 Oct 2011 at 11:49 PM. Reason: additional information

  7. #37

    Default Re: I've deleted products. How do I redirect customers to new ones? or to search inst

    Hello

    did you find the way to make it work with 1.3.9h?

    I tried, it redirects ok but creates a PHP fatal error for the line 188:

    $zco_notifier->notify('NOTIFY_MAIN_TEMPLATE_VARS_EXTRA_PRODUCT_INFO');

    PHP Warning: require(/my/site/domain.com/includes/templates/custom/templates) [<a href='function.require'>function.require</a>]: failed to open stream: No such file or directory in /my/site/domain.com/includes/modules/pages/product_info/main_template_vars.php on line 188
    [19-Feb-2012 19:50:27] PHP Fatal error: require() [<a href='function.require'>function.require</a>]: Failed opening required 'includes/templates/custom/templates' (include_path='.:/usr/local/lib/php') in /my/site/domain.com/includes/modules/pages/product_info/main_template_vars.php on line 188

    ...

 

 
Page 4 of 4 FirstFirst ... 234

Similar Threads

  1. How do I redirect old links to new products?
    By diamond1 in forum General Questions
    Replies: 5
    Last Post: 12 Oct 2013, 11:28 AM
  2. Replies: 1
    Last Post: 25 Feb 2013, 02:27 AM
  3. Replies: 7
    Last Post: 2 Sep 2011, 10:30 AM
  4. Redirect deleted, moved and discontinued products to the home page.
    By Podgeminster in forum General Questions
    Replies: 1
    Last Post: 15 Mar 2011, 02:11 AM
  5. I deleted ALL my banners, now I can't add new ones
    By adod in forum Basic Configuration
    Replies: 5
    Last Post: 13 Nov 2008, 01:29 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR