WordPress.org

Ready to get started?Download WordPress

Forums

BulletProof Security
[resolved] 301 Redirect. (17 posts)

  1. JoshBowers
    Member
    Posted 2 years ago #

    I'm trying to figure out how to do a 301 redirect with this plugin activated.

    Here is the redirect:

    Options +FollowSymlinks
    RewriteEngine on
    rewriterule ^menowhat.htm(.*)$ http://menalive.com/male-menopause-andropause-quiz/$1 [r=301,nc]

    Where do I go to add this? I tried in the Edit/Upload area but when I try to update it just sends me to 404 Error Page.

    Any help appreciated as I figure this should be simple but I am missing something.

    http://wordpress.org/extend/plugins/bulletproof-security/

  2. AITpro
    Member
    Plugin Author

    Posted 2 years ago #

    # Redirect old file path to new file path
    Redirect /olddirectory/menowhat.htm http://menalive.com/male-menopause-andropause-quiz/new-file.php

    You would add your custom .htaccess code to the Bottom Root Custom Code text area, create a new secure.htaccess file with AutoMagic and activate BulletProof Mode for your Root folder.

  3. JoshBowers
    Member
    Posted 2 years ago #

    When I try to create the secure HTACCESS file I get a 404 error

    Should I uninstall and re-install the plugin? If so are there any steps to this I should know before doing?

  4. AITpro
    Member
    Plugin Author

    Posted 2 years ago #

    If you are getting 404 errors then something is wrong with your website URL linking structure.
    Are you using DNS in your control panel?
    Have your tried to hide your wp-admin folder?
    I see that you have 2 WordPress sites.
    have you used the AutoMagic buttons to create your Master .htaccess files first before activating BulletProof Modes?

    This may have something to do with the problem - when i go to your blog site and click on a post i am sent to your main site. Please check all of your WordPress Settings under Settings >>> General Settings to make sure your URLs are correct for each site.

  5. JoshBowers
    Member
    Posted 2 years ago #

    Can you link me to the other wordpress site? I can't even find it on the server.

    I uninstalled and reinstalled the BPS plugin but the 404 is still happening which is a but confusing as I had already used it when the site was originally setup (default htacces, bullet proof mode, etc). I'm a bit perplexed why these issues are coming up now.

    I don't have access to the control panel as that is the previous developers login info and she refuses to let me login.

    I also deleted the htaccess file, which messed up the urls so I rebuilt it through saving the permalinks setting.

    Don't want you to spend time doing tech support on this but if you have any quick ideas I'd appreciate it.

  6. AITpro
    Member
    Plugin Author

    Posted 2 years ago #

    Whoops you do not have 2 WordPress sites. it looks like you just have one WordPress site with a menu item / page called /the-blog.

    I just thought of something obvious - have you activated ALL BulletProof Modes? Root BulletProof Mode and wp-admin BulletProof Mode MUST be activated together. Also you should not have any .htaccess code that is doing any kind of Rewriting in the wp-admin .htaccess file. That .htaccess code should only go in your Root .htaccess file.

    if that is not the problem then whatever is causing the 404 errors has to do with a problem with your URL linking structure. I cannot check any of that from the front side of your website. You would have to check all your WordPress URL settings, permalinks, etc to see what might be the problem.

  7. JoshBowers
    Member
    Posted 2 years ago #

    Activated all BPS things I could.
    Still get the 404 when I try to create the default HTACCESS.
    I can put custom code in the bottom custom code area but it doesn't seem to do anything.

    I've sent a message to the person who hosts the site and has access to the control panel.

    I'm not sure how to check the url link structure other than the permalinks in the general settings which is set to /%postname%/.

    If I figure it out I'll post back. And if I hear anything useful from the site admin I'll post back. Thanks AITpro for all the advice, appreciate it.

  8. AITpro
    Member
    Plugin Author

    Posted 2 years ago #

    Sounds like your Server is configured with DSO and not CGI. What do you see for your SAPI type on the BPS System Info page? If you see DSO then you will have to either change folder permissions to use the automated features in BPS or you will just have to do everything manually instead of being able to use any of the automated copy and write functions in BPS. In other words you would have to use good old fashioned FTP upload or Web Host Control File manager uploading.

  9. JoshBowers
    Member
    Posted 2 years ago #

    Server API: cgi-fcgi - Your Host Server is using CGI.
    Document Root Path: /home/creation/public_html/menalive
    WP ABSPATH: /home/creation/public_html/menalive/
    Parent Directory: /home/creation/public_html

    I'd love to be able to do it manually but when I tried to add the redirect to the htaccess file it messed everything up so I put it back the way it was.

    Can I edit the htaccess file manually at all?

  10. AITpro
    Member
    Plugin Author

    Posted 2 years ago #

    hmm ok now i am completely out of ideas. I cannot see a problem at all so i am not sure why BPS is not working correctly on your website unless you have WP database damage or some other website coding problem. Have you tried deactivating all other plugins and then seeing if BPS works correctly?

    yes you can manually edit the .htaccess file by downloading it, making your edits and then uploading it back to your website.

  11. JoshBowers
    Member
    Posted 2 years ago #

    Yeah I'm lost too.

    I downloaded the HTACCESS and it has the newest BPS version.

    So I added the redirect to the bottom:
    # Redirect old file path to new file path
    Redirect /olddirectory/menowhat.htm http://menalive.com/male-menopause-andropause-quiz/new-file.php

    And it does nothing. Tried a few different ways and still nothing.

    So I'm lost. BPS seems to be working but when I click the "create htaccess" buttons I get redirected to 404, but the htaccess seems to be getting created as everything is normal otherwise (the htaccess has all the right stuff in it and is getting updated).

    But even when manually updating the htaccess I can't seem to get the 301 redirect to work.

    I'm just going to leave it alone until I hear back from the person who hosts it (which is useless really since they don't even know wordpress or databases, just old html).

    If a solution comes up I'll post back.

  12. AITpro
    Member
    Plugin Author

    Posted 2 years ago #

    Well the example i gave you was just an example and actually i left out the 301 part of it. whoops.

    Redirect 301 /example-oldpage.html http://www.example.com/example-newpage.html

    So you would actually have to add the real path and file names in order for the redirect to do anything.

    Yeah if you ever figure out what is going on with your site that is causing this then yep post that info back here.

    In general a 404 error means that a link is not valid so if something is wrong with your URL linking structure then you will see 404 errors, but i have seen some web hosts use a generic 404 template that will be displayed when the actual errors are 403 errors. Not sure if you already changed the file permissions on your root .htaccess file, but try manually changing it to 644 permissions and see what happens.

    Thanks

  13. eatpaintchic
    Member
    Posted 2 years ago #

    I am having this same problem - put the custom 301 redirect to old HTML site (moved to WordPress so want to redirect old links).

    No change - all old links still arrive at the 404 page. Any updates found, please post!

  14. AITpro
    Member
    Plugin Author

    Posted 2 years ago #

    Since this is not a problem or issue directly related to BPS, here are some Google Search results that you can take a look at and in general you can Google "htaccess 301 redirect" and you will find thousands of sites and posts about how to do this.

    http://www.isitebuild.com/301-redirect.htm
    http://www.tamingthebeast.net/articles3/spiders-301-redirect.htm

  15. eatpaintchic
    Member
    Posted 2 years ago #

    Found a simple plugin that worked: http://wordpress.org/extend/plugins/simple-301-redirects/

    Still using BPS, no conflict there.

  16. hunzaboy
    Member
    Posted 1 year ago #

    Worked PERFECTLY!

    redirect 301 /old-path /new-path

    added in custom code bottom...

    That's it

  17. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    A lot of folks ask about how to create the actual htaccess redirect code itself so I put together a tutorial here that covers some basic to advanced htaccess redirect code >>> http://forum.ait-pro.com/forums/topic/htaccess-redirect-code-where-do-i-add-redirect-htaccess-code/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.