Publish rel="me" in Link HTTP headers

This commit is contained in:
Mikael Nordfeldth 2016-02-24 16:43:09 +01:00
parent 731fd01139
commit 1d0a448e07

View File

@ -155,6 +155,17 @@ class ShowstreamAction extends NoticestreamAction
sprintf(_('FOAF for %s'), $this->target->getNickname()))); sprintf(_('FOAF for %s'), $this->target->getNickname())));
} }
public function extraHeaders()
{
parent::extraHeaders();
// Publish all the rel="me" in the HTTP headers on our main profile page
if (get_class($this) == 'ShowstreamAction') {
foreach ($this->target->getRelMes() as $relMe) {
header('Link: <'.htmlspecialchars($relMe['href']).'>'.$type.'; rel="me"', false);
}
}
}
function extraHead() function extraHead()
{ {
if ($this->target->bio) { if ($this->target->bio) {