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

I got SS to install - would love to know how


Reply


1026 Views

Avatar
Nuttydo

Community Member, 16 Posts

18 November 2008 at 9:19am

Edited: 18/11/2008 9:22am

Hi,

This is a post which is part answer for those having trouble installing SilverStripe on shared hosting servers, in particular 1&1 (1 & 1, One & one, whatever they're called) and part request for help from those who can help me make sense of what I did right.

The situation: I couldn't get SS to install at all.

First problem: When I called the install.php page I got a parse error or a white page.

This was caused by the fact that the default PHP on the webserver was 4 and I needed PHP5. The problem was solved by creating a new htaccess file telling the server to load PHP5 - ask your hosting company for the file. I used this:
AddType x-mapp-php5 .php
AddHandler x-mapp-php5 .php

Second problem: Now the install screen appeared but there were warnings telling me that 1) SS couldn't tell which software was on the sever and 2) couldn't tell whether mod_rewrite was working or enabled.

I clicked install and it went through the install, including populating the tables in the database. But then it hit a problem saying that mod_rewrite didn't seem to be working but I could force it to go on.

This then resulted in a parse error in the manifestbuilder line 35.

I tried out various solutions, some from this forum and others from elsewhere.

Suggestions were:

1. Tell the htaccess file to force mod_rewrite - a forum member gave an example and my provider told me a version. But it didn't work.
2. Create a php.ini file in which the command allow_url_fopen was set to 'on'. My provider told me that, for security reasons, it was off in PHP5 but you could force it on in one folder by putting a command in a php.ini file that you place in that folder. The command switched allow_url_fopen on but still didn't result in install success.
3. Got a new htaccess file from my provider with mod_rewrite in it:
AddType x-mapp-php5 .php
AddHandler x-mapp-php5 .php

RewriteEngine on
RewriteCond % index/(.*)\.html$
RewriteRule index/(.*)\.html$ /index.php?kategorie=$1

The long and short of it is, I went away, had a cup of tea, had a bath, came back, started install again by putting in the htaccess file AddType x-mapp-php5 .php / AddHandler x-mapp-php5 .php (as above) and voila, it worked.

I did however get 2 warnings:

Warning: file_get_contents() [function.file-get-contents]: URL file-access is disabled in the server configuration in /homepages/0/d68570838/htdocs/sprachlernstrategien/ss_site/rewritetest.php on line 47

Warning: file_get_contents(http://sprachlernstrategien.de/ss_site/InstallerTest/testrewrite) [function.file-get-contents]: failed to open stream: no suitable wrapper could be found in /homepages/0/d68570838/htdocs/sprachlernstrategien/ss_site/rewritetest.php on line 47
mod_rewrite is working! I will now try and direct you to home/successfullyinstalled to confirm that the installation was successful.

It still works, though!

But how did it work? Was it the php.ini file? Or did the allow_url_fopen command do the trick? Or was it the new htaccess command from my provider? Or was it the mix? And should I be worried about those two warnings?

What I understand is that servers don't update immediately when you request changes, but on regular intervals. Could it be that one of the above did the trick and was then available for install?

To new SS installers - if at first you don't succeed, you know the rest
To clever programmers there: what brought about success. I'm trying to install it elsewhere, linked to a differnet database and haven't got it to work yet. Would be great to know what I did right.

Any ideas?