Updates for release 2.1.x
Dieser Commit ist enthalten in:
Ursprung
9a7442ae41
Commit
2f5f75ba60
|
@ -272,6 +272,7 @@ class cDirHandler {
|
|||
* array containing file names as string, false on error
|
||||
*/
|
||||
public static function read($dirname, $recursive = false, $dirOnly = false, $fileOnly = false) {
|
||||
$dirname = rtrim($dirname, '/') . '/';
|
||||
if (!self::exists($dirname)) {
|
||||
return false;
|
||||
}
|
||||
|
@ -279,7 +280,6 @@ class cDirHandler {
|
|||
$dirContent = array();
|
||||
if ($recursive == false) {
|
||||
$dirHandle = opendir($dirname);
|
||||
$dirContent = array();
|
||||
while (false !== ($file = readdir($dirHandle))) {
|
||||
if (!cFileHandler::fileNameIsDot($file)) {
|
||||
|
||||
|
@ -289,7 +289,9 @@ class cDirHandler {
|
|||
$dirContent[] = $file;
|
||||
}
|
||||
// bugfix: is_dir only checked file name without path, thus returning everything most of the time
|
||||
} else if ($fileOnly === true) { // get only files
|
||||
}
|
||||
|
||||
if ($fileOnly == true && !$dirOnly) { // get only files
|
||||
|
||||
if (is_file($dirname . $file)) {
|
||||
$dirContent[] = $file;
|
||||
|
@ -323,7 +325,6 @@ class cDirHandler {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $dirContent;
|
||||
}
|
||||
|
||||
|
|
Datei-Diff unterdrückt, da er zu groß ist
Diff laden
|
@ -71,7 +71,7 @@ if (!defined('CL_ENVIRONMENT')) {
|
|||
*/
|
||||
if (!defined('CL_VERSION')) {
|
||||
|
||||
define('CL_VERSION', '2.1.0');
|
||||
define('CL_VERSION', '2.1.0');
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -1,36 +1,30 @@
|
|||
################################################################################
|
||||
# CONTENIDO AMR plugin restrictive rewrite rules set.
|
||||
# ConLite AMR plugin restrictive rewrite rules set.
|
||||
#
|
||||
# Contains strict rules, each rewrite exclusion must be set manually.
|
||||
# - Exclude requests to directories usage/, contenido/, setup/, cms/upload/
|
||||
# - Exclude requests to cms/front_content.php
|
||||
# - Exclude requests to directories usage/, conlite/, setup/, cms/upload/
|
||||
# - Exclude requests to cms/front_content.php, cms/dbfs.php
|
||||
# - Pass thru requests to common ressources (pictures, movies, js, css, pdf)
|
||||
#
|
||||
# @version 0.0.1
|
||||
# @version 1.0.0
|
||||
# @author Ortwin Pinke <ortwin.pinke@php-backoffice.de>
|
||||
# @author Murat Purc <murat@purc.de>
|
||||
# @copyright four for business AG <www.4fb.de>
|
||||
# @license http://www.contenido.org/license/LIZENZ.txt
|
||||
# @link http://www.4fb.de
|
||||
# @link http://www.contenido.org
|
||||
# @copyright 2019 ConLite Team
|
||||
# @link http://www.conlite.org
|
||||
#
|
||||
# Versions before 1.0 copyright 4fb, author Murat Purc
|
||||
#
|
||||
# $Id$
|
||||
################################################################################
|
||||
|
||||
|
||||
# Enable following lines to run PHP5 on 1und1.de (1and1.com)
|
||||
#AddType x-mapp-php5 .php
|
||||
#AddHandler x-mapp-php5 .php
|
||||
|
||||
<IfModule mod_rewrite.c>
|
||||
|
||||
# Enable rewrite engine
|
||||
RewriteEngine on
|
||||
|
||||
|
||||
# Specify a base URL-path for the rules
|
||||
RewriteBase /cms
|
||||
|
||||
|
||||
# Catch some common exploits in query string to get rid of them.
|
||||
# NOTE: Conditions to prevent protocols (ftp, http[s]) in query string could
|
||||
# be a disadvantage in some cases.
|
||||
|
@ -42,7 +36,6 @@
|
|||
RewriteCond %{QUERY_STRING} http[s]*://.*$ [NC]
|
||||
RewriteRule ^.* - [F,L] # all matching conditions from above will end in nirvana
|
||||
|
||||
|
||||
# Exclude some files and directories from rewriting
|
||||
RewriteRule ^usage/.*$ - [L]
|
||||
RewriteRule ^conlite/.*$ - [L]
|
||||
|
@ -50,15 +43,14 @@
|
|||
RewriteRule ^cms/upload/.*$ - [L]
|
||||
RewriteRule ^cms/test/.*$ - [L]
|
||||
RewriteRule ^cms/front_content.php.*$ - [L]
|
||||
|
||||
RewriteRule ^cms/dbfs.php.*$ - [L]
|
||||
|
||||
# Exclude common extensions from rewriting and pass remaining requests to
|
||||
# front_content.php.
|
||||
RewriteRule !\.(avi|css|doc|flv|gif|gzip|ico|jpeg|jpg|js|mov|mp3|pdf|png|ppt|rar|swf|txt|wav|wmv|xml|zip)$ front_content.php [NC,QSA,L]
|
||||
RewriteRule !\.(avi|css|doc|flv|gif|gzip|ico|jpeg|jpg|js|mov|mp3|pdf|png|ppt|rar|svg|swf|txt|wav|wmv|xml|zip)$ front_content.php [NC,QSA,L]
|
||||
|
||||
</IfModule>
|
||||
|
||||
|
||||
# Some rules to compress files.
|
||||
# NOTE: Following settings are not mod rewrite specific, but enabling mod_deflate
|
||||
# for some file types can help to reduce bandwith.
|
||||
|
|
|
@ -1,33 +1,27 @@
|
|||
################################################################################
|
||||
# CONTENIDO AMR plugin simple rewrite rules set.
|
||||
# ConLite AMR plugin simple rewrite rules set.
|
||||
#
|
||||
# Contains few easy to handle rewrite rules.
|
||||
#
|
||||
# @version 0.0.1
|
||||
# @version 1.0.0
|
||||
# @author Ortwin Pinke <ortwin.pinke@php-backoffice.de>
|
||||
# @author Murat Purc <murat@purc.de>
|
||||
# @copyright four for business AG <www.4fb.de>
|
||||
# @license http://www.contenido.org/license/LIZENZ.txt
|
||||
# @link http://www.4fb.de
|
||||
# @link http://www.contenido.org
|
||||
# @copyright 2019 ConLite Team
|
||||
# @link http://www.conlite.org
|
||||
#
|
||||
# Versions before 1.0 copyright 4fb, author Murat Purc
|
||||
#
|
||||
# $Id$
|
||||
################################################################################
|
||||
|
||||
|
||||
# Enable following lines to run PHP5 on 1und1.de (1and1.com)
|
||||
#AddType x-mapp-php5 .php
|
||||
#AddHandler x-mapp-php5 .php
|
||||
|
||||
<IfModule mod_rewrite.c>
|
||||
|
||||
# Enable rewrite engine
|
||||
RewriteEngine on
|
||||
|
||||
|
||||
# Specify a base URL-path for the rules
|
||||
RewriteBase /cms
|
||||
|
||||
|
||||
# Catch some common exploits in query string to get rid of them
|
||||
# NOTE: Conditions to prevent protocols (ftp, http[s]) in query string could
|
||||
# be a disadvantage in some cases
|
||||
|
@ -39,11 +33,9 @@
|
|||
RewriteCond %{QUERY_STRING} http[s]*://.*$ [NC]
|
||||
RewriteRule ^.* - [F,L] # all matching conditions from above will end in nirvana
|
||||
|
||||
|
||||
# Rewrite request to root to front_content.php
|
||||
RewriteRule ^$ front_content.php [QSA,L]
|
||||
|
||||
|
||||
# Exclude following request from rewriting
|
||||
# tests for favicon.ico, valid symlinks (-s), not empty files (-l) and folders (-d)
|
||||
RewriteCond %{REQUEST_URI} ^/favicon.ico$ [OR]
|
||||
|
@ -52,13 +44,11 @@
|
|||
RewriteCond %{REQUEST_FILENAME} -d
|
||||
RewriteRule ^.*$ - [NC,L]
|
||||
|
||||
|
||||
# Pass other requests to front_content.php
|
||||
RewriteRule ^.*$ front_content.php [QSA,NC,L]
|
||||
|
||||
</IfModule>
|
||||
|
||||
|
||||
# Some rules to compress files.
|
||||
# NOTE: Following settings are not mod rewrite specific, but enabling mod_deflate
|
||||
# for some file types can help to reduce bandwith.
|
||||
|
|
Laden…
In neuem Issue referenzieren