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.

Archive /

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

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

Installing into Folder not Root directory - "Home Page" gives directory listing


Reply


6 Posts   2425 Views

Avatar
Free

Community Member, 3 Posts

18 June 2008 at 10:17pm

Edited: 18/06/2008 10:23pm

Hey Folks,

Searched the forums and found no real answer. I have successfully installed SilverStripe on several servers but always to the root. I'm currently building a site for a company with an existing website. I installed SilverStripe into a folder on their server so that I can build the new site without disturbing the old one. It runs fine mostly with the exception of the "Home Page" (example www.mysite.com/silver or www.mysite.com/silver/home) all I see is the directory listing. But all other pages work fine I can even login and access the CMS. Is there something I modify to make the "Home Page" work? Also when I'm done building the site and ready to move SilverStripe to the Root is there anything I should be aware of beyond making a backup and moving all the files and folders to the Root?

Thanks Guys

Avatar
gakenny

Community Member, 153 Posts

18 June 2008 at 10:42pm

Hello,

This has to do with the rewrite rules in the .htaccess rules contained in the root folder of the silverstripe installation.

I wonder if changing:
RewriteBase /

To:
RewriteBase /silver

Would help resolve the issue.

Cheers,

Gary

Avatar
gakenny

Community Member, 153 Posts

18 June 2008 at 10:45pm

Hello,

I have just tested this change and it works just fine.

Make sure you reupload the file in ASCII format.

Cheers,

Gary

Avatar
Free

Community Member, 3 Posts

19 June 2008 at 5:39am

Thanks GAKENNY .htaccess configured to "RewriteBase /silver" www.mysite.com/silver/home now works as does www.mysite.com/silver/ but I did notice that if I remove "/" at the end (example www.mysite.com/silver) it still give the directory listing of files. I found a post with the similar problem http://www.silverstripe.com/site-builders-forum/flat/91272 I don't understand the answer given.

Avatar
SaulBretado

Community Member, 4 Posts

21 June 2008 at 4:00pm

Edited: 21/06/2008 5:12pm

I did this on my .htaccess, and it works very well:

### SILVERSTRIPE START ###
### Remove the next 3 lines ###
<IfModule mod_dir.c>
DirectorySlash Off
</IfModule>
#######################

### MORE CODE GOES HERE ###
### SILVERSTRIPE END ###
-------------------------------------------
I hope this works for you too!

Avatar
Free

Community Member, 3 Posts

24 June 2008 at 4:39am

saulbretado

Thanks works great