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

Installing SilverStripe 2.4.3 on home.pl (Polish ISP)


Reply

3 Posts   1580 Views

Avatar
DzikiLis

17 December 2010 at 6:53am Community Member, 1 Post

Hello,

There is an easy way to install SilverStripe on home.pl. They use IdeaWebServer instead of Apache, so you have to make changes in .htaccess files before uploading them:

1) .htaccess (located in main folder) - replace:

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

with following lines:

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

RewriteCond %{REQUEST_FILENAME} index..* [NC]
RewriteRule .* sapphire/main.php?url=/ [L]

2) cms/.htaccess - delete this file (IdeaWebServer's <FilesMatch> syntax is incompatibile with Apache).

Hope this helps.

s.

Avatar
qlex

18 April 2013 at 9:52pm (Last edited: 18 April 2013 9:53pm), Community Member, 68 Posts

Hey, just to confirm this is also valid for Silverstripe 3.0.5. Replacing sapphire with framework, so a working .htaccess is:

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

<Files web.config>
   Order deny,allow
   Deny from all
</Files>

# This denies access to all yml files, since developers might include sensitive
# information in them. See the docs for work-arounds to serve some yaml files
<Files *.yml>
   Order allow,deny
   Deny from all
</Files>

ErrorDocument 404 /assets/error-404.html
ErrorDocument 500 /assets/error-500.html

<IfModule mod_alias.c>
   RedirectMatch 403 /silverstripe-cache(/|$)
   RedirectMatch 403 /vendor(/|$)
   RedirectMatch 403 /composer\.(json|lock)
</IfModule>

<IfModule mod_rewrite.c>
   SetEnv HTTP_MOD_REWRITE On
   RewriteEngine On

RewriteCond %{REQUEST_URI} !(.gif)|(.jpg)|(.png)|(.css)|(.js)|(.php)$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ framework/main.php?url=$1&%{QUERY_STRING} [L]

RewriteCond %{REQUEST_FILENAME} index..* [NC]
RewriteRule .* framework/main.php?url=/ [L]

</IfModule>
### SILVERSTRIPE END ###

Avatar
EDi

11 June 2013 at 3:46am Community Member, 5 Posts

After these changes the site works fine, even most of the admin sections, except for ./admin/pages. It's loading, but after a while all <body> of the document is being removed, leaving me with empty browser window and only <head> in the inspector. If I jump into the /admin through /admin/assets, I can browse every section except 'Pages'.

In most cases without any JS errors. Sometimes with this one:

XHR finished loading: "http://.../test/admin/pages/listview".    
jquery.js:8240
XHR finished loading: "http://.../test/admin/pages/treeview".    
jquery.js:8240
Uncaught TypeError: Cannot call method 'appendChild' of null

Any help will be appreciated, because Home.pl's support is unable to help me for over a week now, and their most valuable proposition was to contact with the cms author. ;)