Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

Archive /

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo

Navigation File Naming Conventions Override Other Software Packages on the Server

Go to End

6 Posts   2308 Views


Community Member, 2 Posts

29 May 2007 at 5:33am

This is not an ultimate deal breaker, but I'm wondering if there's a way around it.

Silverstripe creates navigation with a directory schema:
Instead of:

As a result, if I pop in the directory level destination to another server package (not silverstripe) I am getting a 404 error... unless I add the actual page. = 404 error because link is a link database ... not part of SS, but a legitimate destination on the server. = the link database.

Okay, normally, I'll tell people to go to ... because I don't have to add index.html... the server will automatically bring up the page.

Plenty of websites have multiple programs and packages running on one server. I'm happy to have silverstripe manage content, but if the URL requested is out of its domain, silverstripe should not, ideally, be controlling the destination page.

Any idea how to disable that?


Administrator, 690 Posts

29 May 2007 at 8:14am

A tweak to the .htaccess file is probably needed. Right now SilverStripe processes any request that isn't a file. It probably needs to process any request that isn't a file OR a directory.

Anyone want to have a go at patching the .htaccess file?


Community Member, 94 Posts

31 May 2007 at 12:18pm

here's a one possibility how to do it for 'CRM' direcory and all it's subdirecotries.
First, move the line

RewriteEngine On

to be the first line in .htaccess, then add

## CRM is not in SilverStripe
RewriteRule ^CRM$ - [L]
RewriteRule ^CRM/.* - [L]

and finaly put lines after

If you many direcotries, you may try 'RewriteMap' option and txt config file.


Community Member, 94 Posts

7 June 2007 at 5:57pm

Here's another solution, move SS to a directory ss/, then in the document root make .htaccess:

RewriteEngine On

# list of directories, which are not handled by SS
RewriteRule ^somedir$ - [L]
RewriteRule ^somedir/.* - [L]

## Averything else to SS
RewriteRule ^(.*)$ ss/$1 [L,QSA]

Then go to the ss/mysite/_config.php and add the line:



Google Summer of Code Hacker, 222 Posts

8 June 2007 at 3:28am

Adding this line to .htaccess:
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule .* sapphire/main.php?url=%1&%{QUERY_STRING} [L]
makes SilverStripe ignore requests for existing directories.

Here is a patch for install.php that adds that line to the .htaccess file:

Hope this helps,

Elijah Lofgren


11 Posts

11 October 2007 at 5:14pm

I accidentally deleted my .htaccess file - well uploaded the local copy from before installation to the remote site (using Dreamweaver). I just clicked on over-write remote file, not thinking...

Could someone please copy and paste the entire contents of the .htaccess file in for me? I'd really appreciate it.

Many thanks,