I have a wildcard ssl installed on my account (My host is Bluehost) and I followed the directions here from Bluehost’s site to install the wildcard SSL. However, when I try and access the site at all it comes up with a 500 internal server error. I am using laravel framework right now for the subdomain, I don’t know if that changes anything, but here is the .htaccess file for the main site (Which is a wordpress site):

# Custom subdomain .htaccess SSL + WordPress
        RewriteCond %{HTTP_HOST} ^admin.mysite.com$
        RewriteCond %{REQUEST_URI} !^/admin/public/
        RewriteRule ^(.*)$ /admin/public/$1
        RewriteCond %{HTTP_HOST} ^admin.mysite.com$
        RewriteRule ^(/)?$ admin/public/index.php [L]
        # End custom subdomain .htaccess


# BEGIN WordPress
AddHandler application/x-httpd-php70s .php
<IfModule mod_rewrite.c>
# Custom maindomain .htaccess WordPress
        RewriteBase /
        RewriteCond %{HTTP_HOST} ^(www.)?mysite.com$
        RewriteRule ^index.php$ - [L]
        RewriteCond %{HTTP_HOST} ^(www.)?mysite.com$
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteRule . /index.php [L]
        # End custom maindomain .htaccess
</IfModule>

# END WordPress

And here is the .htaccess file for the subdomain (the one with laravel installed):

<IfModule mod_rewrite.c>
    <IfModule mod_negotiation.c>
        Options -MultiViews
    </IfModule>

    RewriteEngine On

    # Redirect Trailing Slashes If Not A Folder...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)/$ /$1 [L,R=301]

    # Handle Front Controller...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^ index.php [L]

    # Handle Authorization Header
    RewriteCond %{HTTP:Authorization} .
    RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
</IfModule>

Keep in mind too, I know nothing about .htaccess or how it works, I just did what the webpage said to do.

Read more here: wildcard ssl .htaccess file causes 500 error on laravel subdomain


Solution:

If you know the solution of this issue, please leave us a reply in Comment section, to update the question.


Wordpress related questions and answers: