4853 Posts in 5331 Topics by 1461 members
|Go to End|
13 May 2009 at 8:33pm
Just figured out how to make Silverstripe run on SiteGround. This is my reply cross-posted from the SiteGround help forum:
Thanks Centry01 for your hint.
Originally it did not worked for me - I was getting
"HttpRequest::__construct() expects at most 3 parameters, 5 given" error when istall finished.
Then after pulling out the remaining of my hair I've finally succeeded.
There were two issues:
1. With Silverstripe 3.2.1 here were more files referencing to HTTPResponse
2. HTTPRequest also needed to be changes to something else. I used the same scheme and renamed it to SSHTTPRequest.
Here is how.
On my Ubuntu machine I've unarchived the Silverstripe distribution and then run
for f in `rgrep -l HTTPResponse SilverStripe-v2.3.1` do; perl -pi -e 's/HTTPResponse/SSHTTPResponse/g' $f; done
for f in `rgrep -l HTTPResponse SilverStripe-v2.3.1` do; perl -pi -e 's/HTTPRequest/SSHTTPRequest/g' $f; done
(Sorry translating the above from zsh to bash, hope the semicolons are in the right places
Then I renamed sapphire/core/control/HTTPResponse.php -> sapphire/core/control/SSHTTPResponse.php and sapphire/core/control/HTTPRequest.php -> sapphire/core/control/SSHTTPRequest.php
Created archive, apploaded it to the SiteGround, put
"AddHandler application/x-httpd-php52 .php .php5 .php4 .php3" to .htaccess and it worked!
PS. Just realised that I should've done "rgrep -l HTTPRequest SilverStripe-v2.3.1" in the second command, but so far so good.
|Go to Top|