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.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

osCommerce and Silverstripe


Reply


4 Posts   1287 Views

Avatar
borriej

Community Member, 267 Posts

1 June 2010 at 3:53am

Hello ppl,

I've got SS 2.3.7 installed in the root. eg www.mysite.com
I recently installed osCommerce in www.mysite.com/webshop

Now when i want to acces a folder (eg www.mysite.com/webshop/admin) it gives the SilverStripe error: Page not found.
But I dont want SS to give me this error, it must do the normal action: go to the index.php in the folder

It would be easy just typing in the index.php, but I want to secure the admin directory with a .htaccess & .htpasswd. I've done this now, but when I log-in I get the SilverStripe error: 'page not found'

Please help ;)

Avatar
AdamJ

Community Member, 145 Posts

1 June 2010 at 12:27pm

Have a look at http://silverstripe.org/customising-the-cms/show/258520?start=0

Avatar
borriej

Community Member, 267 Posts

1 June 2010 at 6:56pm

Added rule to the .htaccess which is in the root of the website:

- RewriteCond %{REQUEST_URI} !/http://www.mydomain.nl/webshop/catalog/admin
- also added an empty file called: '__manifest_exclude' into the admin folder

(mydomain replaced by my website ofcourse)

It still doens't work:
- I get the log-in box, enter user/pass and then: Website Error - Not Found

Avatar
borriej

Community Member, 267 Posts

1 June 2010 at 9:46pm

### SILVERSTRIPE START ###
<Files *.ss>
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Files>

htaccess looks like this:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /

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

RewriteCond %{REQUEST_URI} ^(.*)$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule .* sapphire/main.php?url=%1&%{QUERY_STRING} [L]
RewriteCond %{REQUEST_URI} !/http://www.mydomain.nl/webshop/catalog/admin/index.php

</IfModule>

### SILVERSTRIPE END ###