aboutsummaryrefslogtreecommitdiff
path: root/install/ElggRewriteTester.php
diff options
context:
space:
mode:
authorBrett Profitt <brett.profitt@gmail.com>2011-06-18 19:56:33 -0400
committerBrett Profitt <brett.profitt@gmail.com>2011-06-18 19:56:33 -0400
commitec7b94a64aef23b85866ecdac8e8acc712d29bb6 (patch)
treea108205c3fa0b694d8ce0ebaafd259480d6b530a /install/ElggRewriteTester.php
parentc80ba5aa03264dd64c20ed8ae222e87f9371a44d (diff)
parent2b68a4d217c35a5587c462620789493cf2804ba2 (diff)
downloadelgg-ec7b94a64aef23b85866ecdac8e8acc712d29bb6.tar.gz
elgg-ec7b94a64aef23b85866ecdac8e8acc712d29bb6.tar.bz2
Merge branch 'master' of github.com:Elgg/Elgg
Diffstat (limited to 'install/ElggRewriteTester.php')
-rw-r--r--install/ElggRewriteTester.php10
1 files changed, 5 insertions, 5 deletions
diff --git a/install/ElggRewriteTester.php b/install/ElggRewriteTester.php
index c8a503cb8..c01510f60 100644
--- a/install/ElggRewriteTester.php
+++ b/install/ElggRewriteTester.php
@@ -30,7 +30,7 @@ class ElggRewriteTester {
*/
public function run($url, $path) {
- $this->guessWebServer();
+ $this->webserver = ElggRewriteTester::guessWebServer();
$this->rewriteTestPassed = $this->runRewriteTest($url);
@@ -48,17 +48,17 @@ class ElggRewriteTester {
/**
* Guess the web server from $_SERVER['SERVER_SOFTWARE']
*
- * @return void
+ * @return string
*/
- protected function guessWebServer() {
+ public static function guessWebServer() {
$serverString = strtolower($_SERVER['SERVER_SOFTWARE']);
$possibleServers = array('apache', 'nginx', 'lighttpd', 'iis');
foreach ($possibleServers as $server) {
if (strpos($serverString, $server) !== FALSE) {
- $this->webserver = $server;
- return;
+ return $server;
}
}
+ return 'unknown';
}
/**