// Before — scattered across every XOOPS module $escaped = htmlspecialchars($value, ENT_QUOTES | ENT_HTML5, 'UTF-8'); $url = XOOPS_URL . '/modules/' . $dirname . '/article.php?id=' . $id; $path = XOOPS_ROOT_PATH . '/modules/' . $dirname . '/language/' . $language . '/blocks.php'; $sitename = $GLOBALS['xoopsConfig']['sitename']; // After $escaped = HtmlBuilder::escape($value); $url = Url::module($dirname, 'article.php', ['id' => $id]); $path = Path::module($dirname, "language/{$language}/blocks.php"); $sitename = Config::get('system.sitename'); That first line is not just shorter — it is structurally safer. Every manual htmlspecialchars() call is a place where a future developer can introduce a stored XSS vulnerability by forgetting it once. HtmlBuilder escapes all attribute values and class names automatically — the source of the vast majority of real-world XSS. Tag content is your responsibility, intentionally: content can legitimately contain HTML (rendered markup, trusted template fragments). The safe path is explicit: pass user-supplied content through HtmlBuilder::escape(). This htmlspecialchars pattern appears 30+ times in the XOOPS Core alone — each one a place where this library makes the correct choice the easiest choice.