You are here

class HamlCdataFilter in Sassy 7

CDATA Filter for {@link http://haml-lang.com/ Haml} class. Surrounds the filtered text with CDATA tags. @package PHamlP @subpackage Haml.filters

Hierarchy

Expanded class hierarchy of HamlCdataFilter

File

phamlp/haml/filters/HamlCdataFilter.php, line 18

View source
class HamlCdataFilter extends HamlBaseFilter {

  /**
   * Run the filter
   * @param string text to filter
   * @return string filtered text
   */
  public function run($text) {
    return "<![CDATA[\n" . preg_replace(HamlParser::MATCH_INTERPOLATION, '<?php echo \\1; ?>', $text) . "  ]]>\n";
  }

}

Members

Namesort descending Modifiers Type Description Overrides
HamlBaseFilter::init public function * Initialise the filter. 2
HamlCdataFilter::run public function * Run the filter * Overrides HamlBaseFilter::run