Forums

htaccess redirects not working (12 posts)

  1. meshmarketer
    Member
    Posted 11 months ago #

    My redirects are not working at all. Anyone know why?

    [post large chunks of code at pastebin.com - thanks]

  2. webjunk
    Member
    Posted 11 months ago #

    We would need to know what kind of redirects you are talking about. If this in htaccess then we need to see your htaccess. If in WP then we need further details , a link to your website & your configuration. Otherwise would just be guessing.

  3. meshmarketer
    Member
    Posted 11 months ago #

    Yes, I had put it there.

    It is in WP and I didn't use pastebin till now:

    PASTEBIN

  4. webjunk
    Member
    Posted 11 months ago #

    Need a valid Pastebin link.

  5. meshmarketer
    Member
    Posted 11 months ago #

    sorry, it was set to private. try again.

  6. webjunk
    Member
    Posted 11 months ago #

    The link is not valid.

  7. meshmarketer
    Member
    Posted 11 months ago #

  8. webjunk
    Member
    Posted 11 months ago #

    As one example from your .htaccess:

    Redirect 301 http://pelvicpainhelp.com/physical_therapy.php http://pelvicpainhelp.com/treatment/physical-therapy-wise-anderson-protocol/

    should be (notice file path instead of web path):
    Redirect 301 /physical_therapy.php http://pelvicpainhelp.com/treatment/physical-therapy-wise-anderson-protocol/

    Also generaly you should not mix "Redirect" with "RewriteRule" in the same .htaccesss. And do you need the redirects in the ifmodule statement? Would put them above so they always run.

    Then go to my tools page:
    http://webjunk.com/tools/
    Use the URL Redirect Checker to see if its working.

  9. meshmarketer
    Member
    Posted 11 months ago #

    I did change the path to test it out and it didn't work. There is something else going on there.

    I don't know if I need them there as I think there were put there by my plugins.

  10. webjunk
    Member
    Posted 11 months ago #

    Put this at the top of your .htaccess and then try my URL Checker.

    RewriteEngine On
    Options +FollowSymLinks

    Redirect 301 /physical_therapy.php http://pelvicpainhelp.com/treatment/physical-therapy-wise-anderson-protocol/

    Make sure in the redirect line that only a single space (no more) can exist between words!

  11. meshmarketer
    Member
    Posted 11 months ago #

    That worked!

  12. webjunk
    Member
    Posted 11 months ago #

    Then you need to fix the rest of your .htaccess in a similar fashion. Then chec not only those redirects but everything else in your .htaccess to make sure they work properly
    Have a nice day!

Reply

You must log in to post.

About this Topic