Project

General

Profile

« Previous | Next » 

Revision 19

Added by Manuela about 7 years ago

output_filter/filters/filterRelUrl little typo fixed

View differences:

branches/main/admin/interface/version.php
43 43

  
44 44
/* -------------------------------------------------------- */
45 45
// Must include code to stop this file being accessed directly
46
if(defined('WB_PATH') == false) { die('Illegale file access /'.basename(__DIR__).'/'.basename(__FILE__).''); }
46
//if(!defined('WB_PATH')) { header("HTTP/1.0 404 Not Found"); flush(); }
47 47
/* -------------------------------------------------------- */
48

  
48
$sInfo = '
49
    VERSION  = "2.10.1-dev"
50
    REVISION = "19"
51
    SP       = ""
52
';
53
//$aIni = parse_ini_string($sInfo);
54
//foreach ($aIni as $item=>$value) {
55
foreach (parse_ini_string($sInfo) as $item=>$value) {
56
    if(!defined($item)) { define($item, $value); }
57
}
49 58
// check if defined to avoid errors during installation (redirect to admin panel fails if PHP error/warnings are enabled)
50 59
if(!defined('VERSION')) { define('VERSION', '2.10.1-dev'); }
51 60
if(!defined('REVISION')) { define('REVISION', '18'); }
branches/main/modules/output_filter/filters/filterRelUrl.php
18 18
                '/((?:href|src|action)\s*=\s*")([^\?\"]+?)/isU',
19 19
                function ($aMatches) use ($sAppUrl, $sAppPath, $sAppRel) {
20 20
                    $aMatches[2] = str_replace('\\', '/', $aMatches[2]);
21
                    if ($aMatches[2][0] ='/') { $aMatches[2] = rtrim($sAppUrl, '/').$aMatches[2]; }
21
                    if ($aMatches[2][0] =='/') { $aMatches[2] = rtrim($sAppUrl, '/').$aMatches[2]; }
22 22
                    $aMatches[2] = preg_replace('/^'.preg_quote($sAppUrl, '/').'/is', '', $aMatches[2]);
23 23
                    $aMatches[2] = preg_replace('/(\.+\/)|(\/+)/', '/', $aMatches[2]);
24 24
                    if (!is_readable($sAppPath.$aMatches[2])) {

Also available in: Unified diff