The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Wordpress and custom permalinks

Discussion in 'Security' started by shimabuku, Jan 8, 2015.

  1. shimabuku

    shimabuku Registered

    Joined:
    Jan 8, 2015
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    I have just added an SSL Cert to one of my domains. This domain uses Wordpress and custom permalinks. When I set Wordpress to use default permalinks all https links work as they should but when I set the permalinks to custom all https links throw a 404 error. I came across this post and was wondering if I could do something similar within WHM/cPanel?

    https://wordpress.org/support/topic...cate-causing-404-error-with-custom-permalinks

    As you can see the poster is using Ubuntu and added the below statements to his default-ssl file. Any help would be greatly appreciated. Thanks!
    Code:
    <VirtualHost _default_:443>
    ServerName <ipaddress>:443
    ServerAdmin webmaster@localhost
    
    DocumentRoot /home/webadmin/public/<website>/public/
    <Directory /home/webadmin/public/<website>/public/ >
    AllowOverride All
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    </Directory>
    
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    675
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    You can modify the SSL VirtualHost for a single domain name using the instructions here:

    Modify Virtualhost Containers With Include Files

    I suggest reviewing the existing VirtualHost in /usr/local/apache/conf/httpd.conf and make changes based on that.

    Thank you.
     
Loading...

Share This Page