{"record":{"id":"e8f0a16e71f1f91a","repo":"getgrav/grav","slug":"400-e8f0a1","errorCode":"400","errorMessage":"Page content resolves to disallowed markup (%s) after Twig processing. Remove the render-time-assembled tag or attribute.","messagePattern":"Page content resolves to disallowed markup \\((.+?)\\) after Twig processing\\. Remove the render-time-assembled tag or attribute\\.","errorType":"validation","errorClass":"RuntimeException","httpStatus":400,"severity":"error","filePath":"system/src/Grav/Common/Page/Page.php","lineNumber":1363,"sourceCode":"        }\n\n        return null;\n    }\n\n    /**\n     * Save page if there's a file assigned to it.\n     *\n     * @param bool|array $reorder Internal use.\n     */\n    public function save($reorder = true)\n    {\n        // Render-time XSS backstop for assembled content Twig, mirroring the Flex\n        // save path (PageObject::onBeforeSave). Belt-and-suspenders for the legacy\n        // save path — reject before writing if the editor's content resolves to\n        // flagged markup once its Twig is processed. (GHSA-2c4f-86xc-cr74)\n        $found = Security::detectXssInEditorContent($this->rawMarkdown(), $this);\n        if ($found !== null) {\n            throw new RuntimeException(\n                sprintf('Page content resolves to disallowed markup (%s) after Twig processing. Remove the render-time-assembled tag or attribute.', $found),\n                400\n            );\n        }\n\n        // Perform move, copy [or reordering] if needed.\n        $this->doRelocation();\n\n        $file = $this->file();\n        if ($file) {\n            $file->filename($this->filePath());\n            $file->header((array)$this->header());\n            $file->markdown($this->rawMarkdown());\n            $file->save();\n        }\n\n        // Perform reorder if required\n        if ($reorder && is_array($reorder)) {","sourceCodeStart":1345,"sourceCodeEnd":1381,"githubUrl":"https://github.com/getgrav/grav/blob/6040efed04efa69b8209448ed81308e7c24147c2/system/src/Grav/Common/Page/Page.php#L1345-L1381","documentation":"Error \"Page content resolves to disallowed markup (%s) after Twig processing. Remove the render-time-assembled tag or attribute.\" thrown in getgrav/grav.","triggerScenarios":"Thrown at system/src/Grav/Common/Page/Page.php:1363 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"6040efed04efa69b8209448ed81308e7c24147c2","analyzedAt":"2026-08-17T05:07:31.593Z","schemaVersion":2},"datasetVersion":"2026-08-17T09:17:11.063Z"}