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.

redirects Url issue

Discussion in 'General Discussion' started by Mardaki, Oct 31, 2013.

  1. Mardaki

    Mardaki Registered

    Joined:
    Oct 31, 2013
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Team,
    I install ssl certificate its working fine but I have issue with Redirects Url how can i change Url from https://domain.com to https://www.domain.com

    Thanks
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

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

    You can force the use of the "www" prefix for SSL by adding the following entries to the .htaccess file in your public_html directory:

    Code:
    RewriteEngine On
    RewriteCond %{HTTP_HOST} ^EXAMPLE.COM$ [NC]
    RewriteCond %{HTTPS} on
    RewriteRule ^(.*)$ https://www.EXAMPLE.COM/$1 [R=301,L]
    Thank you.
     
  3. Mardaki

    Mardaki Registered

    Joined:
    Oct 31, 2013
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Thanks Mate
     
Loading...

Share This Page