Results 1 to 5 of 5
  1. #1
    Join Date
    Apr 2007
    Posts
    152
    Plugin Contributions
    0

    Default trying to set up a 301 redirect by editing .htaccess file

    Hi
    i have opened this file up with bbedit and also gone onto my server cpanal>edit code, but there seems to be no code in there is this correct? i am trying to set up a 301 redirect as i have just done a website grade from website.grader.com and they say my site has Permanent Redirect Not Found

    any ideas how to get this to work.

  2. #2
    Join Date
    Oct 2006
    Location
    Alberta, Canada
    Posts
    4,571
    Plugin Contributions
    1

    Default Re: trying to set up a 301 redirect by editing .htaccess file

    Need more information to provide a good answer.

    Steps to reproduct the problems would be helpful as well.

  3. #3
    Join Date
    Nov 2007
    Location
    Woodbine, Georgia, United States
    Posts
    4,025
    Plugin Contributions
    61

    Default Re: trying to set up a 301 redirect by editing .htaccess file

    http://www.beyondink.com/howtos/301-redirect.php

    Don't edit files like the ones above in anything like BB code.... PLain old notepad.. NOT wordpad or MS word.

    PSPad works great and has added notepad function - Freeware

    ~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.

  4. #4
    Join Date
    Apr 2007
    Posts
    152
    Plugin Contributions
    0

    Default Re: trying to set up a 301 redirect by editing .htaccess file

    i followed the link you gave me and i see this code but i really dont know the purpose of what i am doing, a redirect to me sounds like i am going to one url and that is telling me to goto another, why would i want to do that at a guess i am thinking its an error page thing?, silly question i know but i haven't really looked into this i am just going on what that website grader said:

    PHP 4 and PHP 5

    Single Page Redirect:

    <?php
    header('HTTP/1.1 301 Moved Permanently');
    header('Location: http://www.new-url.com/');
    ?>

    Canonical Hostname Redirect (non-www to www):

    <%
    If InStr(Request.ServerVariables("SERVER_NAME"),"www") = 0 Then
    Response.Status="301 Moved Permanently"
    Response.AddHeader "Location","http://www." & Request.ServerVariables("HTTP_HOST") & Request.ServerVariables("SCRIPT_NAME")
    Response.End
    End if
    %>

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

    Default Re: trying to set up a 301 redirect by editing .htaccess file

    Then back to Rob's answer we need more information... the codes you posted do not belong in your htaccess.

    ~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.

 

 

Similar Threads

  1. Can't login after adding a 301 redirect in .htaccess
    By eutopia in forum Basic Configuration
    Replies: 0
    Last Post: 11 Oct 2011, 02:27 AM
  2. Ultimate SEO Module + htaccess 301 redirect issue
    By justinanderson007 in forum All Other Contributions/Addons
    Replies: 6
    Last Post: 31 Aug 2010, 04:12 PM
  3. Replies: 1
    Last Post: 3 May 2009, 05:16 AM
  4. 301 redirect in htaccess not working
    By FrenchFrog in forum General Questions
    Replies: 10
    Last Post: 24 Aug 2007, 12:36 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