Project

General

Profile

« Previous | Next » 

Revision 802

Added by doc over 16 years ago

Added workaround for the template parser class

View differences:

trunk/CHANGELOG
12 12

  
13 13
------------------------------------- 2.7.0 -------------------------------------
14 14
05-Apr-2008 Christian Sommer
15
!	added workaround for template parser class
15 16
!	moved functions to edit module CSS files into the WB core to avoid duplication of code
16 17
!	minor layout change
17 18
!	allowed the character "-" to be used in database names
trunk/wb/include/phplib/template.inc
1 1
<?php
2

  
3
// $Id$
4

  
2 5
/*
3 6
 * Session Management for PHP3
4 7
 *
......
345 348
    $str = $this->get_var($parent);
346 349
    $reg = "/[ \t]*<!--\s+BEGIN $varname\s+-->\s*?\n?(\s*.*?\n?)\s*<!--\s+END $varname\s+-->\s*?\n?/sm";
347 350
    preg_match_all($reg, $str, $m);
351
/* workaround to avoid problems with some WB files/modules (e.g. massmail)
348 352
    if (!isset($m[1][0])) {
349 353
      $this->halt("set_block: unable to set block $varname.");
350 354
      return false;
351 355
    }
356
*/
352 357
    $str = preg_replace($reg, "{" . $name . "}", $str);
353
    $this->set_var($varname, $m[1][0]);
358
    @$this->set_var($varname, $m[1][0]);
354 359
    $this->set_var($parent, $str);
355 360
    return true;
356 361
  }

Also available in: Unified diff