Announcement

Collapse
No announcement yet.

SSL is not working with permalink in WordPress

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • SSL is not working with permalink in WordPress

    I just installed SSL on a website and the index page is working well.

    All pages and archives are working properly if the permalink settings are set to default. But itís showing a 404 error for all pages and categories if I change the permalink settings to another preference.

    I am using woo-commerce plugin. Does it matter anyway?

  • #2
    Can you please post htaccess code here?

    Comment


    • #3
      Originally posted by Hadley View Post
      Can you please post htaccess code here?
      Code:
      # BEGIN WordPress
      <IfModule mod_rewrite.c>
      RewriteEngine On
      RewriteBase /
      RewriteRule ^index\.php$ - [L]
      RewriteCond %{REQUEST_FILENAME} !-f
      RewriteCond %{REQUEST_FILENAME} !-d
      RewriteRule . /index.php [L]
      </IfModule>
      # END WordPress

      Comment


      • #4
        How did you installed the SSL? Did you try to disable all plugins one by one?

        Comment


        • #5
          I have just changed the blog URL and WP address to HTTPS instead of HTTP. Also, SSL and HTTPS is configured properly and working well on VPS.

          Comment


          • #6
            I have no some way or another of htaccess yet I attempted a few codes found from all over however none of them works for me. Images, JS and CSS files of my site is loading fine with HTTPS. Just pages and archives are showing 404.

            Comment


            • #7
              Would you be able to please provide the way how you get links to archives and pages? Navigation menus, in-built functions? Are these hard-coded in templates or elsewhere? Have you attempted SSL with the default template but without plugins?

              Comment


              • #8
                Iím not using any plugin and no links are hard-coded. Navigation menus and functions are just used to print out links.

                Comment


                • #9
                  What protocol display in the address bar when you get the 404 error? And what happens after you change it manually?

                  Comment


                  • #10
                    Originally posted by Connor View Post
                    What protocol display in the address bar when you get the 404 error? And what happens after you change it manually?
                    Not sure. 404 I think.

                    Comment


                    • #11
                      Ensure mod_rewrite is enabled as Apache module. It is not required while plain permalinks are used, however, you have the reverse situation. Add following code to .htaccess file before or inside the WordPress section:

                      RewriteEngine On
                      # The following lines are essential
                      RewriteCond %{HTTPS} !=on
                      RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
                      And remember set up the SSL for Check Out pages in the WooCommerce settings.

                      Comment


                      • #12
                        Thank you Nimbus for helping me. I checked that mod_rewrite is already enabled and I had added that htaccess code several times before. At this time I have added it again in htaccess and just restarted Apache. But nothing happened.

                        Comment


                        • #13
                          I think itís not a WordPress fault. You have to check Apache configuration again.

                          Comment


                          • #14
                            Oh.. I was looking at WordPress end. Now it working fine by modifying Apache config file.
                            Thanks a lot Nimbus for helping me out.

                            Comment

                            Working...
                            X