protected function isBlockEnd($line, $blockName = null)
    {
        $line = trim($line);
        $pattern = '/^\<\/';
        $pattern .= ($blockName) ? $blockName : '[^\s\>]+';
        $pattern .= '\>$/';
        return (preg_match($pattern, $line) > 0);
    }
protected function isBlockEnd($line, $blockName = null)
    {
        $line = trim($line);
        $pattern = '/^\<\/';
        $pattern .= ($blockName) ? $blockName : '[^\s\>]+';
        $pattern .= '\>$/';
        return (preg_match($pattern, $line) > 0);
    }
protected function isBlockEnd ( $ line , $ blockName = null ) { $ line = trim ( $ line ) ; $ pattern = '/^\<\/' ; $ pattern .= ( $ blockName ) ? $ blockName : '[^\s\>]+' ; $ pattern .= '\>$/' ; return ( preg_match ( $ pattern , $ line ) > 0 ) ; }
Check if line is a Block end

@param string $line
@param string $blockName [optional] The block's name
@return bool
Check if line is a Block end