2 require_once __DIR__ . '/../data/config.php';
3 require_once __DIR__ . '/functions.php';
4 header('Link: <' . $hub . '>; rel="hub"');
5 header('Link: <' . $self . '>; rel="self"', false);
7 $articles = loadArticles();
9 <html xmlns="http://www.w3.org/1999/xhtml">
11 <title>WebSub tester</title>
12 <link rel="alternate" type="application/atom+xml" title="WebSub tester" href="feed.php" />
16 <a href="add-article.php">create new article</a>
17 | <a href="feed.php">atom feed</a>
20 This is a tool to test your <a href="https://www.w3.org/TR/websub/">WebSub</a>
22 With one click, a new post gets published and the hub gets notified.
25 <?php foreach ($articles as $article) { ?>
26 <article class="h-entry">
27 <h2><?php echo htmlspecialchars($article->title); ?></h2>
28 <div class="e-content">
29 <?php echo $article->content; ?>
32 <a href="<?php echo $article->file; ?>" class="u-url">permalink</a>
33 at <time class="dt-published"><?php echo date('c', $article->time); ?></time>
35 <span class="h-card vcard author p-author">
36 <img class="u-photo" src="someone.png" width="16" height="16" alt=""/>
37 <a class="p-author h-card" href="someone.htm">Someone</a>