mirror of
https://github.com/silverstripe/silverstripe-installer
synced 2024-10-22 15:05:33 +00:00
#1874 - generated .htaccess lacks "Rewritebase"
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/phpinstaller/trunk@47868 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
40fe857bfb
commit
b2156f92bc
20
install.php
20
install.php
@ -737,10 +737,12 @@ PHP
|
||||
|
||||
function createHtaccess() {
|
||||
$start = "### SILVERSTRIPE START ###\n";
|
||||
$end= "\n### SILVERSTRIPE END ###";
|
||||
$end = "\n### SILVERSTRIPE END ###";
|
||||
$base = dirname($_SERVER['SCRIPT_NAME']);
|
||||
|
||||
$rewrite = <<<TEXT
|
||||
RewriteEngine On
|
||||
|
||||
RewriteBase $base
|
||||
|
||||
RewriteCond %{REQUEST_URI} !(\.gif)|(\.jpg)|(\.png)|(\.css)|(\.js)|(\.php)$
|
||||
|
||||
@ -750,11 +752,6 @@ RewriteRule .* sapphire/main.php?url=%1&%{QUERY_STRING} [L]
|
||||
TEXT
|
||||
;
|
||||
|
||||
$baseURL = dirname($_SERVER['SCRIPT_NAME']);
|
||||
if($baseURL == "/") {
|
||||
$baseURL = "";
|
||||
}
|
||||
|
||||
if(file_exists('.htaccess')) {
|
||||
$htaccess = file_get_contents('.htaccess');
|
||||
|
||||
@ -773,9 +770,12 @@ TEXT
|
||||
|
||||
function createHtaccessAlternative() {
|
||||
$start = "### SILVERSTRIPE START ###\n";
|
||||
$end= "\n### SILVERSTRIPE END ###";
|
||||
$end= "\n### SILVERSTRIPE END ###";
|
||||
$base = dirname($_SERVER['SCRIPT_NAME']);
|
||||
|
||||
$rewrite = <<<TEXT
|
||||
RewriteEngine On
|
||||
RewriteBase $base
|
||||
|
||||
RewriteCond %{REQUEST_URI} !(\.gif)|(\.jpg)|(\.png)|(\.css)|(\.js)|(\.php)$
|
||||
|
||||
@ -785,10 +785,6 @@ RewriteRule .* $_SERVER[DOCUMENT_ROOT]/sapphire/main.php?url=%1&%{QUERY_STRING}
|
||||
TEXT
|
||||
;
|
||||
|
||||
$baseURL = dirname($_SERVER['SCRIPT_NAME']);
|
||||
if($baseURL == "/") {
|
||||
$baseURL = "";
|
||||
}
|
||||
|
||||
if(file_exists('.htaccess')) {
|
||||
$htaccess = file_get_contents('.htaccess');
|
||||
|
@ -75,8 +75,11 @@ function performModRewriteTest() {
|
||||
function createHtaccess() {
|
||||
$start = "### SILVERSTRIPE START ###\n";
|
||||
$end= "\n### SILVERSTRIPE END ###";
|
||||
$base = dirname($_SERVER['SCRIPT_NAME']);
|
||||
|
||||
$rewrite = <<<TEXT
|
||||
RewriteEngine On
|
||||
RewriteBase $base
|
||||
|
||||
RewriteCond %{REQUEST_URI} !(\.gif)|(\.jpg)|(\.png)|(\.css)|(\.js)|(\.php)$
|
||||
|
||||
@ -86,10 +89,6 @@ RewriteRule .* sapphire/main.php?url=%1&%{QUERY_STRING} [L]
|
||||
TEXT
|
||||
;
|
||||
|
||||
$baseURL = dirname($_SERVER['SCRIPT_NAME']);
|
||||
if($baseURL == "/") {
|
||||
$baseURL = "";
|
||||
}
|
||||
if(file_exists('.htaccess')) {
|
||||
$htaccess = file_get_contents('.htaccess');
|
||||
|
||||
@ -109,8 +108,11 @@ TEXT
|
||||
function createHtaccessAlternative() {
|
||||
$start = "### SILVERSTRIPE START ###\n";
|
||||
$end= "\n### SILVERSTRIPE END ###";
|
||||
$base = dirname($_SERVER['SCRIPT_NAME']);
|
||||
|
||||
$rewrite = <<<TEXT
|
||||
RewriteEngine On
|
||||
RewriteBase $base
|
||||
|
||||
RewriteCond %{REQUEST_URI} !(\.gif)|(\.jpg)|(\.png)|(\.css)|(\.js)|(\.php)$
|
||||
|
||||
@ -119,12 +121,7 @@ RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteRule .* $_SERVER[DOCUMENT_ROOT]/sapphire/main.php?url=%1&%{QUERY_STRING} [L]
|
||||
TEXT
|
||||
;
|
||||
|
||||
$baseURL = dirname($_SERVER['SCRIPT_NAME']);
|
||||
if($baseURL == "/") {
|
||||
$baseURL = "";
|
||||
}
|
||||
|
||||
|
||||
if(file_exists('.htaccess')) {
|
||||
$htaccess = file_get_contents('.htaccess');
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user