mirror of
https://github.com/silverstripe/silverstripe-installer
synced 2024-09-30 05:09:10 +02:00
Merge remote-tracking branch 'origin/3.1'
Conflicts: composer.json
This commit is contained in:
commit
cd56f026ce
10
.htaccess
10
.htaccess
@ -10,11 +10,20 @@
|
|||||||
Deny from all
|
Deny from all
|
||||||
</Files>
|
</Files>
|
||||||
|
|
||||||
|
# This denies access to all yml files, since developers might include sensitive
|
||||||
|
# information in them. See the docs for work-arounds to serve some yaml files
|
||||||
|
<Files *.yml>
|
||||||
|
Order allow,deny
|
||||||
|
Deny from all
|
||||||
|
</Files>
|
||||||
|
|
||||||
ErrorDocument 404 /assets/error-404.html
|
ErrorDocument 404 /assets/error-404.html
|
||||||
ErrorDocument 500 /assets/error-500.html
|
ErrorDocument 500 /assets/error-500.html
|
||||||
|
|
||||||
<IfModule mod_alias.c>
|
<IfModule mod_alias.c>
|
||||||
RedirectMatch 403 /silverstripe-cache(/|$)
|
RedirectMatch 403 /silverstripe-cache(/|$)
|
||||||
|
RedirectMatch 403 /vendor(/|$)
|
||||||
|
RedirectMatch 403 /composer\.(json|lock)
|
||||||
</IfModule>
|
</IfModule>
|
||||||
|
|
||||||
<IfModule mod_rewrite.c>
|
<IfModule mod_rewrite.c>
|
||||||
@ -23,6 +32,7 @@ ErrorDocument 500 /assets/error-500.html
|
|||||||
|
|
||||||
RewriteCond %{REQUEST_URI} ^(.*)$
|
RewriteCond %{REQUEST_URI} ^(.*)$
|
||||||
RewriteCond %{REQUEST_FILENAME} !-f
|
RewriteCond %{REQUEST_FILENAME} !-f
|
||||||
|
RewriteCond %{REQUEST_URI} !\.php$
|
||||||
RewriteRule .* framework/main.php?url=%1 [QSA]
|
RewriteRule .* framework/main.php?url=%1 [QSA]
|
||||||
|
|
||||||
RewriteCond %{REQUEST_URI} ^(.*)/framework/main.php$
|
RewriteCond %{REQUEST_URI} ^(.*)/framework/main.php$
|
||||||
|
@ -8,11 +8,5 @@ $database = '';
|
|||||||
|
|
||||||
require_once('conf/ConfigureFromEnv.php');
|
require_once('conf/ConfigureFromEnv.php');
|
||||||
|
|
||||||
MySQLDatabase::set_connection_charset('utf8');
|
// Set the site locale
|
||||||
|
i18n::set_locale('en_US');
|
||||||
// Set the current theme. More themes can be downloaded from
|
|
||||||
// http://www.silverstripe.org/themes/
|
|
||||||
SSViewer::set_theme('simple');
|
|
||||||
|
|
||||||
// Enable nested URLs for this site (e.g. page/sub-page/)
|
|
||||||
if(class_exists('SiteTree')) SiteTree::enable_nested_urls();
|
|
9
mysite/_config/config.yml
Normal file
9
mysite/_config/config.yml
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
---
|
||||||
|
Name: mysite
|
||||||
|
After: 'framework/*','cms/*'
|
||||||
|
---
|
||||||
|
# YAML configuration for SilverStripe
|
||||||
|
# See http://doc.silverstripe.org/framework/en/topics/configuration
|
||||||
|
# Caution: Indentation through two spaces, not tabs
|
||||||
|
SSViewer:
|
||||||
|
theme: 'simple'
|
@ -1,10 +1,10 @@
|
|||||||
<?php
|
<?php
|
||||||
class Page extends SiteTree {
|
class Page extends SiteTree {
|
||||||
|
|
||||||
public static $db = array(
|
private static $db = array(
|
||||||
);
|
);
|
||||||
|
|
||||||
public static $has_one = array(
|
private static $has_one = array(
|
||||||
);
|
);
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -25,7 +25,7 @@ class Page_Controller extends ContentController {
|
|||||||
*
|
*
|
||||||
* @var array
|
* @var array
|
||||||
*/
|
*/
|
||||||
public static $allowed_actions = array (
|
private static $allowed_actions = array (
|
||||||
);
|
);
|
||||||
|
|
||||||
public function init() {
|
public function init() {
|
||||||
|
15
web.config
15
web.config
@ -1,5 +1,18 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<configuration>
|
<configuration>
|
||||||
<system.webServer>
|
<system.webServer>
|
||||||
|
<security>
|
||||||
|
<requestFiltering>
|
||||||
|
<hiddenSegments>
|
||||||
|
<add segment="silverstripe-cache/" />
|
||||||
|
<add segment="vendor" />
|
||||||
|
<add segment="composer.json" />
|
||||||
|
<add segment="composer.lock" />
|
||||||
|
</hiddenSegments>
|
||||||
|
<fileExtensions allowUnlisted="true" >
|
||||||
|
<add fileExtension=".ss" allowed="false"/>
|
||||||
|
<add fileExtension=".yml" allowed="false"/>
|
||||||
|
</fileExtensions>
|
||||||
|
</requestFiltering>
|
||||||
|
</security>
|
||||||
</system.webServer>
|
</system.webServer>
|
||||||
</configuration>
|
</configuration>
|
Loading…
Reference in New Issue
Block a user