AnsweredAssumed Answered

Redirect to subdirectory

Question asked by Jeff H on Jul 24, 2014

During installation, I installed Sugar in a subdirectory under the wwwroot (var/www/html). I created a DNS entry so that I can use sugar.myURL.com but I still have to use the /Sugar at the end. This appears to be handled through the .htaccess file (per this http://tips-scripts.com/?pointing).

This works but Sugar just sits at a loading screen.  I can still type in /sugar and get into the system fine.  What am I missing?


This is my .htaccess (under my root folder)

RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_URI} !^/subdirectory/
RewriteCond %{HTTP_HOST} ^(www\.)?myurl.com\.
RewriteRule ^(.*)$ subdirectory/$1 [L]

Outcomes