Merge branch 'master' into pico-1.1

Conflicts:
	lib/Pico.php
This commit is contained in:
Daniel Rudolf 2017-07-18 21:39:39 +02:00
commit 3e88c58ce0
No known key found for this signature in database
GPG key ID: A061F02CD8DE4538
2 changed files with 9 additions and 2 deletions

View file

@ -3,7 +3,7 @@ Pico
[![License](https://picocms.github.io/badges/pico-license.svg)](https://github.com/picocms/Pico/blob/master/LICENSE.md)
[![Version](https://picocms.github.io/badges/pico-version.svg)](https://github.com/picocms/Pico/releases/latest)
[![Build Status](https://api.travis-ci.org/picocms/Pico.svg)](https://travis-ci.org/picocms/Pico)
[![Build Status](https://api.travis-ci.org/picocms/Pico.svg?branch=master)](https://travis-ci.org/picocms/Pico)
[![Freenode IRC Webchat](https://picocms.github.io/badges/pico-chat.svg)](https://webchat.freenode.net/?channels=%23picocms)
Pico is a stupidly simple, blazing fast, flat file CMS.

View file

@ -1830,7 +1830,14 @@ class Pico
return $urlRewritingEnabled;
}
$this->config['rewrite_url'] = (isset($_SERVER['PICO_URL_REWRITING']) && $_SERVER['PICO_URL_REWRITING']);
if (isset($_SERVER['PICO_URL_REWRITING'])) {
$this->config['rewrite_url'] = (bool) $_SERVER['PICO_URL_REWRITING'];
} elseif (isset($_SERVER['REDIRECT_PICO_URL_REWRITING'])) {
$this->config['rewrite_url'] = (bool) $_SERVER['REDIRECT_PICO_URL_REWRITING'];
} else {
$this->config['rewrite_url'] = false;
}
return $this->config['rewrite_url'];
}