add author, url and photo
authorChristian Weiske <cweiske@cweiske.de>
Thu, 26 Mar 2015 19:14:43 +0000 (20:14 +0100)
committerChristian Weiske <cweiske@cweiske.de>
Thu, 26 Mar 2015 19:14:43 +0000 (20:14 +0100)
www/add-article.php
www/index.php
www/someone.htm [new file with mode: 0644]
www/someone.png [new file with mode: 0644]

index 25db71e..ee24c9b 100644 (file)
@@ -17,6 +17,12 @@ file_put_contents(
  </head>
  <body class="h-entry">
   <h1>$title</h1>
+  <p>
+   <span class="h-card vcard author p-author">
+    <img class="u-photo" src="../someone.png" width="16" height="16" alt=""/>
+    <a class="p-author h-card" href="../someone.htm">Someone</a>
+   </span>
+  </p>
   <div class="e-content">$content</div>
  </body>
 </html>
index b4d0b2f..0eaefb6 100644 (file)
@@ -23,8 +23,9 @@ krsort($articles);
   <title>PubSubHubbub tester</title>
  </head>
  <body class="h-feed">
+  <iframe src="" id="addview" name="addview" style="position: absolute; right: 0.5ex; width: 60ex; height: 10ex; border: 1px solid grey"></iframe>
   <p>
-   <a href="add-article.php">create new article</a>
+   <a href="add-article.php" target="addview">create new article</a>
   </p>
   <h1>Articles</h1>
   <?php foreach ($articles as $article) { ?>
@@ -35,7 +36,12 @@ krsort($articles);
     </div>
     <p>
      <a href="<?php echo $article->file; ?>" class="u-url">permalink</a>
-      <time class="dt-published"><?php echo date('c', $article->time); ?></time>
+     at <time class="dt-published"><?php echo date('c', $article->time); ?></time>
+     by
+     <span class="h-card vcard author p-author">
+      <img class="u-photo" src="someone.png" width="16" height="16" alt=""/>
+      <a class="p-author h-card" href="someone.htm">Someone</a>
+     </span>
     </p>
    </article>
   <?php } ?>
diff --git a/www/someone.htm b/www/someone.htm
new file mode 100644 (file)
index 0000000..b2f08d5
--- /dev/null
@@ -0,0 +1,12 @@
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>Someone</title>
+ </head>
+ <body>
+  <h1>Someone</h1>
+  <img class="u-photo" src="someone.png" width="16" height="16" alt=""/>
+  <p>
+   Is the author of this <a href="./">blog</a>.
+  </p>
+ </body>
+</html>
diff --git a/www/someone.png b/www/someone.png
new file mode 100644 (file)
index 0000000..0d0d732
Binary files /dev/null and b/www/someone.png differ