git.cweiske.de
/
anoweco.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Simple latest comment list
[anoweco.git]
/
www
/
comment.php
diff --git
a/www/comment.php
b/www/comment.php
index b1fe2d762e601b40df33ab5a0c50a3eab53591ff..e3843610c9b1a555c21d8e47a389d0a1c50dcc96 100644
(file)
--- a/
www/comment.php
+++ b/
www/comment.php
@@
-18,7
+18,7
@@
if (!is_numeric($_GET['id'])) {
$id = intval($_GET['id']);
$storage = new Storage();
$id = intval($_GET['id']);
$storage = new Storage();
-$comment = $storage->getComment($id);
+$comment = $storage->get
Json
Comment($id);
if ($comment === null) {
header('HTTP/1.0 404 Not Found');
header('Content-Type: text/plain');
if ($comment === null) {
header('HTTP/1.0 404 Not Found');
header('Content-Type: text/plain');
@@
-38,8
+38,10
@@
$vars = array(
'url' => Urls::full(Urls::user($rowUser->user_id)),
'imageurl' => Urls::userImg($rowUser),
),
'url' => Urls::full(Urls::user($rowUser->user_id)),
'imageurl' => Urls::userImg($rowUser),
),
+ 'postUrl' => Urls::full(Urls::comment($rowComment->comment_id)),
'replyUrl' => Urls::full(
'replyUrl' => Urls::full(
- '/reply.php?url=' . urlencode(Urls::full($rowComment->comment_id))
+ '/reply.php?url='
+ . urlencode(Urls::full(Urls::comment($rowComment->comment_id)))
),
);
),
);
@@
-56,5
+58,10
@@
if ($rowComment->comment_type == 'like') {
$vars['htmlContent'] = $htmlContent;
}
$vars['htmlContent'] = $htmlContent;
}
+if (isset($linkbackEndpoint) && $linkbackEndpoint) {
+ header('X-Pingback: ' . $linkbackEndpoint);
+ header('Link: <' . $linkbackEndpoint . '>; rel="webmention"');
+}
+
render($template, $vars);
?>
render($template, $vars);
?>