I’m writing a PHP tutorial. Of course, when I echo HTML tags they get interpreted by the browser, so I do this:
$output .= str_replace('<', '<', $output);
$output .= str_replace('>', '>', $output);
But then, at $output I have this <div class=“example”>, so I DO NOT WANT html to get interpreted only if is surrounded by the div class=“example”. All other HTML tags outsite the div class=“example” should be interpreted.
Suggestions?