xml_exception.php 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. /**
  3. * SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors
  4. * SPDX-FileCopyrightText: 2012-2015 ownCloud, Inc.
  5. * SPDX-License-Identifier: AGPL-3.0-only
  6. */
  7. require_once __DIR__ . '/print_xml_exception.php';
  8. print_unescaped('<?xml version="1.0" encoding="utf-8"?>' . "\n");
  9. ?>
  10. <d:error xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns">
  11. <s:exception><?php p($l->t('Internal Server Error')) ?></s:exception>
  12. <s:message>
  13. <?php p($l->t('The server was unable to complete your request.')) ?>
  14. <?php p($l->t('If this happens again, please send the technical details below to the server administrator.')) ?>
  15. <?php p($l->t('More details can be found in the server log.')) ?>
  16. <?php if (isset($_['serverLogsDocumentation']) && $_['serverLogsDocumentation'] !== ''): ?>
  17. <?php p($l->t('For more details see the documentation ↗.'))?>: <?php print_unescaped($_['serverLogsDocumentation']) ?>
  18. <?php endif; ?>
  19. </s:message>
  20. <s:technical-details>
  21. <s:remote-address><?php p($_['remoteAddr']) ?></s:remote-address>
  22. <s:request-id><?php p($_['requestID']) ?></s:request-id>
  23. <?php if (isset($_['debugMode']) && $_['debugMode'] === true): ?>
  24. <s:type><?php p($_['errorClass']) ?></s:type>
  25. <s:code><?php p($_['errorCode']) ?></s:code>
  26. <s:message><?php p($_['errorMsg']) ?></s:message>
  27. <s:file><?php p($_['file']) ?></s:file>
  28. <s:line><?php p($_['line']) ?></s:line>
  29. <s:stacktrace>
  30. <?php print_exception($_['exception'], $l); ?>
  31. </s:stacktrace>
  32. <?php endif; ?>
  33. </s:technical-details>
  34. </d:error>