Jump to content

Rewriting links with .htaccess - Problem with WHMCS installed on subdomain


bosco07

Recommended Posts

Hello, so i have installed WHMCS in a subdomain, like customers.website.com.

In my website's .htaccess file i have a code to rewrite the adress without WWW to adress with WWW so my website's pages will always be http://www.website.com.

 

The problem is that i have noticed it also rewrites my subdomain's links, where i have WHMCS install, so if i click Domain Check in my client area, the url is rewritten to http://www.subdomain.website.com, and that is very ugly and odd, and also creating some problems with cookies i think, and maybe even SEO problems.

 

So i'm asking is there a way to rewrite my website's adress to "always with WWW" using its .htaccess file, and somehow make an exception for the subdomain ?

 

Here is the code i have in my website's .htaccess file, not in the WHMCS ( subdomain ) one.

 

RewriteEngine On

RewriteCond %{HTTP_HOST} ^website.com

RewriteRule (.*) http://www.website.com/$1 [R=301,L]

Link to comment
Share on other sites

  • 3 years later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated