/** * Run the rewrite test and return a status array * * @param string $url URL of rewrite test * @param string $path Root directory of Elgg with trailing slash * * @return array */ public function run($url, $path) { $this->webserver = \ElggRewriteTester::guessWebServer(); $this->rewriteTestPassed = $this->runRewriteTest($url); if ($this->rewriteTestPassed == FALSE) { if ($this->webserver == 'apache' || $this->webserver == 'unknown') { if ($this->createHtaccess($url, $path)) { $this->rewriteTestPassed = $this->runRewriteTest($url); } } } return $this->returnStatus($url); }