summaryrefslogtreecommitdiff
path: root/LibertySystem.php
diff options
context:
space:
mode:
authorMax Kremmel <xing@synapse.plus.com>2006-04-10 17:38:44 +0000
committerMax Kremmel <xing@synapse.plus.com>2006-04-10 17:38:44 +0000
commit5c24b0d4ae4930c138b17bebed0f47cf9272b8ba (patch)
tree4f7096e73571686933942b4286f3287a7a23856e /LibertySystem.php
parentb308ebfb62b791ff109aa9f0bb98d288624d61a3 (diff)
downloadliberty-5c24b0d4ae4930c138b17bebed0f47cf9272b8ba.tar.gz
liberty-5c24b0d4ae4930c138b17bebed0f47cf9272b8ba.tar.bz2
liberty-5c24b0d4ae4930c138b17bebed0f47cf9272b8ba.zip
revert recent changes. didn't work as expected.
Diffstat (limited to 'LibertySystem.php')
-rwxr-xr-xLibertySystem.php21
1 files changed, 4 insertions, 17 deletions
diff --git a/LibertySystem.php b/LibertySystem.php
index f3bdd5f..406cb42 100755
--- a/LibertySystem.php
+++ b/LibertySystem.php
@@ -3,7 +3,7 @@
* System class for handling the liberty package
*
* @package liberty
-* @version $Header: /cvsroot/bitweaver/_bit_liberty/LibertySystem.php,v 1.23 2006/04/10 13:58:10 squareing Exp $
+* @version $Header: /cvsroot/bitweaver/_bit_liberty/LibertySystem.php,v 1.24 2006/04/10 17:38:44 squareing Exp $
* @author spider <spider@steelsun.com>
*/
@@ -278,7 +278,7 @@ class LibertySystem extends LibertyBase {
}
function parse_data_plugins( &$data, &$preparsed, &$noparsed, &$pParser ) {
- global $gLibertySystem, $gParsedDataPlugins;
+ global $gLibertySystem;
// Find the plugins
// note: $curlyTags[0] is the complete match, $curlyTags[1] is plugin name, $curlyTags[2] is plugin arguments
preg_match_all("/\{\/?([A-Za-z]+)([^\}]*)\}/", $data, $curlyTags);
@@ -387,10 +387,8 @@ function parse_data_plugins( &$data, &$preparsed, &$noparsed, &$pParser ) {
$ret = preg_replace( "/\~(\/?)[np]p\~/", '', $ret );
}
- // pass plugin output to hash and place a unique key in the text for later replacement
- $key = md5( microtime( rand() ) );
- $gParsedDataPlugins[$key] = $ret;
- $data = substr_replace( $data, $key, $pos, $pos_end - $pos + strlen( $plugin_end ) );
+ // Replace plugin section with its output in data
+ $data = substr_replace($data, $ret, $pos, $pos_end - $pos + strlen($plugin_end));
}
}
$i--;
@@ -403,17 +401,6 @@ function parse_data_plugins( &$data, &$preparsed, &$noparsed, &$pParser ) {
}
}
-// parse_data_plugins places all plugin data in $gParsedDataPlugins. The plugin
-// data is passed back into $data once all the parsing has finished
-function post_parse_data( &$pData ) {
- global $gParsedDataPlugins;
- if( !empty( $gParsedDataPlugins ) && is_array( $gParsedDataPlugins ) ) {
- foreach( $gParsedDataPlugins as $key => $data ) {
- $pData = str_replace( $key, $data, $pData );
- }
- }
-}
-
global $gLibertySystem;
$gLibertySystem = new LibertySystem();
?>