| @@ 1681-1690 (lines=10) @@ | ||
| 1678 | $content = str_replace(array('<?php', '<?=', '<?', '?>'), array("{$sp}b", "{$sp}p", "{$sp}s", "{$sp}e"), $content); |
|
| 1679 | ||
| 1680 | $pieces = explode('<@IF:', $content); |
|
| 1681 | foreach ($pieces as $i => $split) { |
|
| 1682 | if ($i === 0) { |
|
| 1683 | $content = $split; |
|
| 1684 | continue; |
|
| 1685 | } |
|
| 1686 | list($cmd, $text) = explode('>', $split, 2); |
|
| 1687 | $cmd = str_replace("'", "\'", $cmd); |
|
| 1688 | $content .= "<?php if(\$this->_parseCTagCMD('" . $cmd . "')): ?>"; |
|
| 1689 | $content .= $text; |
|
| 1690 | } |
|
| 1691 | $pieces = explode('<@ELSEIF:', $content); |
|
| 1692 | foreach ($pieces as $i => $split) { |
|
| 1693 | if ($i === 0) { |
|
| @@ 1692-1701 (lines=10) @@ | ||
| 1689 | $content .= $text; |
|
| 1690 | } |
|
| 1691 | $pieces = explode('<@ELSEIF:', $content); |
|
| 1692 | foreach ($pieces as $i => $split) { |
|
| 1693 | if ($i === 0) { |
|
| 1694 | $content = $split; |
|
| 1695 | continue; |
|
| 1696 | } |
|
| 1697 | list($cmd, $text) = explode('>', $split, 2); |
|
| 1698 | $cmd = str_replace("'", "\'", $cmd); |
|
| 1699 | $content .= "<?php elseif(\$this->_parseCTagCMD('" . $cmd . "')): ?>"; |
|
| 1700 | $content .= $text; |
|
| 1701 | } |
|
| 1702 | ||
| 1703 | $content = str_replace(array('<@ELSE>', '<@ENDIF>'), array('<?php else:?>', '<?php endif;?>'), $content); |
|
| 1704 | ob_start(); |
|