Extension talk:NukeHtmlPhp
Add topicAppearance
Latest comment: 17 years ago by Jldupont
It might even be better (if you want to clean the page) to change the code to
<?php $text = str_ireplace ("<tag>", "<notag>", $text); $text = str_ireplace ("<tag1>", "<notag>", $text); // etc.. $text = preg_replace ("/<notag>[^<]*<\/notag>/", "", $text); //perhaps a message or null ?>
The only problem with this script is that if there's a page in which a user with rights posted a <php> tag it will be removed/changed even if no changes are made to the page. --Johnny3 10:36, 30 January 2007 (UTC)
If you look at the update of this extension (link provided on the main page), you will find it integrates better with GeSHi syntax highlighter; when a user does not have the necessary 'coding' right, the extension changes the <tag> to one that GeSHi recognizes and the code gets highlighted instead. Jldupont 17:54, 30 January 2007 (UTC)