mirror of
https://github.com/jimeh/dlist.git
synced 2026-02-19 07:56:41 +00:00
updates, edits and shit...
- changed configuration system, so at the point init.php runs only settings needed by init.php are set, the rest are loaded later if init.php doesn't redirect to an index file... git-svn-id: file:///Users/jimeh/Desktop/dlist/trunk@8 a5845835-ea0f-0410-a762-dd0bfe9bfde8
This commit is contained in:
@@ -23,7 +23,7 @@ class execHandler {
|
||||
var $cache_data = '.data.cache.php';
|
||||
var $cache_details = '.details.cache.php';
|
||||
var $cache_time = '.time.cache.php';
|
||||
var $update_frequency = 0;
|
||||
var $update_frequency = 10;
|
||||
var $php_opentag = "<?php\n";
|
||||
var $php_closetag = "\n?>";
|
||||
|
||||
@@ -32,6 +32,7 @@ class execHandler {
|
||||
|
||||
var $default_stages = array(
|
||||
'init' => 10,
|
||||
'query' => 20,
|
||||
'main' => 50,
|
||||
'render' => 80,
|
||||
'term' => 90,
|
||||
@@ -421,9 +422,10 @@ class execHandler {
|
||||
|
||||
// Compiling
|
||||
|
||||
function clean_up_code ($string, $comments=true, $emptylines=true) {
|
||||
function clean_up_code ($string, $comments=true, $emptylines=true, $indents=false) {
|
||||
if ( $comments ) $string = $this->remove_comments($string);
|
||||
if ( $emptylines ) $string = $this->remove_empty_lines($string);
|
||||
if ( $indents ) $string = $this->remove_indents($string);
|
||||
return trim($string);
|
||||
}
|
||||
|
||||
@@ -438,6 +440,11 @@ class execHandler {
|
||||
$string = preg_replace("/\n+/m", "\n", $string);
|
||||
return $string;
|
||||
}
|
||||
|
||||
function remove_indents ($string) {
|
||||
$string = preg_replace("/\n\s+(.*)/", "\n$1", $string);
|
||||
return $string;
|
||||
}
|
||||
|
||||
|
||||
// Cache
|
||||
|
||||
Reference in New Issue
Block a user