nl2br_except_pre($str)
Parameters: |
|
---|---|
Returns: |
Formatted string |
Return type: |
string |
Converts newlines to <br /> tags unless they appear within <pre> tags. This method is identical to the native PHP nl2br()
function, except that it ignores <pre> tags.
Usage example:
1 | $string = $this ->typography->nl2br_except_pre( $string ); |
Please login to continue.