Highlight replies
rodzic
edbf35c4d3
commit
ce30c1d378
15
index.php
15
index.php
|
@ -1152,7 +1152,7 @@ HTML;
|
|||
|
||||
// Displays the most recent 200 messages in the inbox
|
||||
function read() {
|
||||
global $server, $directories;
|
||||
global $server, $username, $directories;
|
||||
|
||||
// Get all the files in the inbox
|
||||
$inbox_files = array_reverse( glob( $directories["inbox"] . "/*.json") );
|
||||
|
@ -1242,9 +1242,18 @@ HTML;
|
|||
}
|
||||
}
|
||||
|
||||
"Create" == $type ? $verb = "wrote" : $verb = "updated";
|
||||
// Check to see if the user has been specifically CC'd
|
||||
$reply = in_array( "https://{$server}/{$username}", $object["cc"] );
|
||||
|
||||
// What sort of message is this?
|
||||
"Create" == $type ? $verb = "wrote" : $verb = "updated";
|
||||
if ( $reply ) {
|
||||
// Highlight that this is a reply
|
||||
echo "<li><mark>{$timeHTML} {$actorHTML} {$verb}:</mark> <blockquote>{$content}</blockquote></li>";
|
||||
} else {
|
||||
echo "<li>{$timeHTML} {$actorHTML} {$verb}: <blockquote>{$content}</blockquote></li>";
|
||||
}
|
||||
|
||||
echo "<li>{$timeHTML} {$actorHTML} {$verb}: <blockquote>{$content}</blockquote></li>";
|
||||
} else if ( "Like" == $type ) {
|
||||
$objectHTML = "<a href=\"$object\">{$object}</a>";
|
||||
echo "<li>{$timeHTML} {$actorHTML} liked {$objectHTML}<br></li>";
|
||||
|
|
Ładowanie…
Reference in New Issue