You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

95 lines
2.9 KiB

  1. <?php $this->layout('layout-loggedin', ['title' => $title, 'accounts' => $accounts, 'user' => $user]); ?>
  2. <div class="ui main text container" style="margin-top: 80px;">
  3. <h2>Webmention Request</h2>
  4. <table class="ui table single line"><tbody>
  5. <tr>
  6. <td><b>Date</b></td>
  7. <td><?= date('M j, g:ia', strtotime($webmention->created_at)) ?></td>
  8. </tr>
  9. <tr>
  10. <td><b>Source</b></td>
  11. <td><a href="<?= $this->e($webmention->source) ?>"><?= $this->e($webmention->source) ?></a></td>
  12. </tr>
  13. <tr>
  14. <td><b>Target</b></td>
  15. <td><a href="<?= $this->e($webmention->target) ?>"><?= $this->e($webmention->target) ?></a></td>
  16. </tr>
  17. <? if($webmention->vouch): ?>
  18. <tr>
  19. <td><b>Vouch</b></td>
  20. <td><a href="<?= $this->e($webmention->vouch) ?>"><?= $this->e($webmention->vouch) ?></a></td>
  21. </tr>
  22. <? endif; ?>
  23. <? if($webmention->callback): ?>
  24. <tr>
  25. <td><b>Callback URL</b></td>
  26. <td><?= $this->e($webmention->callback) ?></td>
  27. </tr>
  28. <? endif; ?>
  29. </tbody></table>
  30. <h2>Details</h2>
  31. <? if(count($statuses) == 0): ?>
  32. <p>The request is queued for processing. Check for updates again later.</p>
  33. <? else: ?>
  34. <table class="ui table single line"><tbody>
  35. <? if($webmention->webmention_endpoint): ?>
  36. <tr>
  37. <td><b>Webmention Endpoint</b></td>
  38. <td><?= $this->e($webmention->webmention_endpoint) ?></td>
  39. </tr>
  40. <? endif; ?>
  41. <? if($webmention->pingback_endpoint): ?>
  42. <tr>
  43. <td><b>Pingback Endpoint</b></td>
  44. <td><?= $this->e($webmention->pingback_endpoint) ?></td>
  45. </tr>
  46. <? endif; ?>
  47. <? if($webmention->webmention_endpoint == false && $webmention->pingback_endpoint == false): ?>
  48. <tr>
  49. <td><b>Webmention Endpoint</b></td>
  50. <td>No webmention endpoint was discovered for this target</td>
  51. </tr>
  52. <? endif; ?>
  53. <? if($webmention->webmention_endpoint): ?>
  54. <tr>
  55. <td><b>Status URL</b></td>
  56. <td><?= $webmention->webmention_status_url ? $this->e($webmention->webmention_status_url) : 'The webmention endpoint did not return a status URL' ?></td>
  57. </tr>
  58. <? endif; ?>
  59. </tbody></table>
  60. <h2>Logs</h2>
  61. <table class="ui very compact table single line">
  62. <thead>
  63. <tr>
  64. <th>Date</th>
  65. <th>Status</th>
  66. <th>HTTP Code</th>
  67. </tr>
  68. </thead>
  69. <tbody>
  70. <? foreach($statuses as $status): ?>
  71. <tr>
  72. <td><?= date('M j, g:ia', strtotime($status->created_at)) ?></td>
  73. <td><?= $status->status ?></td>
  74. <td><?= $status->http_code ?></td>
  75. </tr>
  76. <tr>
  77. <td colspan="3">
  78. <pre style="font-size: 10px;"><?= $this->e($status->raw_response) ?></pre>
  79. </td>
  80. </tr>
  81. <? endforeach; ?>
  82. </tbody>
  83. </table>
  84. <? endif; ?>
  85. </div>