Exemple #1
0
 /**
  * Inject close
  */
 public function injectClosing(NodeInterface $child, NodeInterface $parent)
 {
     if ($child instanceof BlockInterface and $source = $child->compileClosingTag()) {
         $content = preg_replace($this->search($child->getExtractionId(static::CLOSING_TAG)), $child->validate() ? $this->php($source) : null, $parent->getCurrentContent(), self::LIMIT);
         $parent->setCurrentContent($content);
     }
 }