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.

Installing SilverStripe

Getting SilverStripe up and running on your computer and on your web server.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Using Wordpress on a Silverstripe Subdomain

Go to End

13 Posts   4979 Views

blue wire

5 February 2009 at 8:59am Community Member, 2 Posts


I couldn't find anything that specifically addressed this topic in the archives. I love Silverstripe, but I also love Wordpress. I want to put a Wordpress install on a subdomain but after I map the subdomain to the proper directory and upload Wordpress I get the following error:

Not Found

The requested URL /sapphire/main.php was not found on this server.

I there something in Silverstripe that doesn't let you make custom subdomains? Am I being stupid?

Thanks for the help.


5 February 2009 at 11:49am Forum Moderator, 5511 Posts

You might need to edit your .htaccess file in your SilverStripe install. It has a 'RewriteBase /' or something. Try changing that path to the path of your silverstripe installation.

blue wire

5 February 2009 at 11:59am (Last edited: 5 February 2009 12:00pm), Community Member, 2 Posts

Thanks for the reply Will-

This is my .htaccess:


redirect 301 /sitemap-2

AddType application/x-httpd-php .htm .html

RewriteEngine On
RewriteBase /

# Canonicalization
RewriteCond %{HTTP_HOST} ^domain\.net
RewriteRule ^(.*)$$1 [R=permanent,L]

RewriteCond %{REQUEST_URI} !(\.gif)|(\.jpg)|(\.png)|(\.css)|(\.js)|(\.php)$

RewriteCond %{REQUEST_URI} ^(.*)$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule .* sapphire/main.php?url=%1&%{QUERY_STRING} [L]


All the Silverstripe files are in 1 directory (e.g. /usr/home/words/public_html/general/

The subdomain is mapped to a file in the above directory (e.g. /usr/home/words/public_html/general/

I uploaded all the Wordpress files to the subdomain directory but when I visit it in a browser I see the following error:

Not Found

The requested URL /sapphire/main.php was not found on this server.


5 February 2009 at 12:11pm Forum Moderator, 5511 Posts

maybe try change RewriteBase / to RewriteBase /usr/home/words/public_html/general/ . Or remove it completely and see what happens!


7 May 2009 at 8:13am Community Member, 33 Posts

I am dealing with this very same issue, blue wire. Can you tell me if you found a solution and what it is?



8 May 2009 at 3:37am Community Member, 395 Posts

easily you can solve this by making the wordpress to use a .htaccess

I think it is on the Reading section of the wordpress CMS, and there is some option, when you select it, it will make readable URLs and it will drop a new .htaccess. with this you can avoid the collisions easily, but still it is not a proper answer I guess ;)


14 May 2009 at 6:28am (Last edited: 14 May 2009 6:29am), Community Member, 12 Posts

Has this been resolved? As I have not been able to get the blog module working, I was hoping to use a Wordpress blog in a subfolder exactly as the user above has.

I cannot get to the Wordpress CMS to create the .htaccess file since it is blocked by SilverStripe.

Thanks for any advice!


14 May 2009 at 6:36am Community Member, 12 Posts

Nevermind, I got it.

The Wordpress subfolder I created was named /blog so I added the following line into my .htaccess file:

RewriteCond %{REQUEST_URI} !/blog

Everything seems to be working now!

Go to Top