page: omit editing <div> container for xml response
authorMischa POSLAWSKY <perl@shiar.org>
Tue, 27 Apr 2021 01:03:11 +0000 (03:03 +0200)
committerMischa POSLAWSKY <perl@shiar.org>
Tue, 27 Apr 2021 14:44:40 +0000 (16:44 +0200)
page.php

index c313467ffe3076674dbe31631a0a25ebbcb29e72..8a37533f4c6e78e928980c5a92454f3e589be83d 100644 (file)
--- a/page.php
+++ b/page.php
@@ -60,7 +60,8 @@ if ($Page->editable = $User->admin("edit {$Page->link}")) {
        include_once 'edit/head.inc.php';
 }
 
-if (isset($Page->raw)) {
+if (isset($Page->raw)
+and @$_SERVER['HTTP_ACCEPT'] !== 'application/xml') {
        $Page->raw = '<div class="static">'."\n\n".$Page->raw."</div>\n\n";
 }