Concrete5 adds unwanted directory to url

Permalink
Hello,

I just installed Concrete5, and so far am very pleased with how things work. However I have one major annoyance, namely:

Concrete5 currently runs on a subdomain of my main domain.
/public_html/brophy/
brophy.mydomain.com

It's working fine, however any link that I click has an extra /brophy/ in the url, which- if anything, should simply be /

This is causing the url to be brophy.mydomain.com/brophy/

Which, if possible, I would like to avoid.

Did I configure something wrong? Can I change it as a setting? Do I need to reinstall?

Any help would be appreciated!

 
goldhat replied on at Permalink Reply
Hopefully somebody with experience running C5 on a subdomain can help you more but I'll suggest I'd try tinkering with the htaccess file to strip away that folder name or have the URL be cleaner. By default your .htaccess file probably has lines like this:

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME}/index.html !-f
RewriteCond %{REQUEST_FILENAME}/index.php !-f
RewriteRule . index.php [L]
WimBarelds replied on at Permalink Reply
As it is, everything works fine. This is because... Well, here's the part of the .htaccess that takes care of the subdomain:

RewriteCond %{HTTP_HOST} ^brophy\.mydomain.com
RewriteCond %{REQUEST_URI} !^/brophy/
RewriteRule ^(.*)$ /brophy/$1

As a result, when it makes every link be /brophy/* it simply doesn't execute the subdomain rewrite rule (because it's already in the right directory). This wasn't exactly planned, but for now it works out fine.

My qualm is with the fact that the CMS prepends every relative url with /brophy/

Is there a way to stop it from doing that? Is it a config thing?
goldhat replied on at Permalink Reply
It's not C5 adding the folder name it's either the htaccess or your server.

Have you tried changing the last line where it seems to add in a folder?

RewriteRule ^(.*)$ /$1
ThemeGuru replied on at Permalink Reply
ThemeGuru
Check the site.php file.

You might need to fix the base_url and the dir_rel.

Hope that helps.