Some more contact paths
This commit is contained in:
parent
09aa496387
commit
98dd4e889a
|
@ -51,6 +51,7 @@ use Friendica\Util\Crypto;
|
||||||
use Friendica\Util\DateTimeFormat;
|
use Friendica\Util\DateTimeFormat;
|
||||||
use Friendica\Util\Images;
|
use Friendica\Util\Images;
|
||||||
use Friendica\Util\Network;
|
use Friendica\Util\Network;
|
||||||
|
use Friendica\Util\Proxy;
|
||||||
use Friendica\Util\Strings;
|
use Friendica\Util\Strings;
|
||||||
use Friendica\Util\XML;
|
use Friendica\Util\XML;
|
||||||
|
|
||||||
|
@ -618,7 +619,8 @@ class DFRN
|
||||||
XML::addElement($doc, $author, "dfrn:handle", $owner["addr"], $attributes);
|
XML::addElement($doc, $author, "dfrn:handle", $owner["addr"], $attributes);
|
||||||
|
|
||||||
$attributes = ["rel" => "photo", "type" => "image/jpeg",
|
$attributes = ["rel" => "photo", "type" => "image/jpeg",
|
||||||
"media:width" => 300, "media:height" => 300, "href" => $owner['photo']];
|
"media:width" => Proxy::PIXEL_SMALL, "media:height" => Proxy::PIXEL_SMALL,
|
||||||
|
"href" => Contact::getAvatarUrlForId($owner['id'], Proxy::SIZE_SMALL, $owner['updated'])];
|
||||||
|
|
||||||
if (!$public || !$hide) {
|
if (!$public || !$hide) {
|
||||||
$attributes["dfrn:updated"] = $picdate;
|
$attributes["dfrn:updated"] = $picdate;
|
||||||
|
|
|
@ -39,6 +39,7 @@ use Friendica\Model\User;
|
||||||
use Friendica\Util\DateTimeFormat;
|
use Friendica\Util\DateTimeFormat;
|
||||||
use Friendica\Util\Network;
|
use Friendica\Util\Network;
|
||||||
use Friendica\Util\ParseUrl;
|
use Friendica\Util\ParseUrl;
|
||||||
|
use Friendica\Util\Proxy;
|
||||||
use Friendica\Util\Strings;
|
use Friendica\Util\Strings;
|
||||||
use Friendica\Util\XML;
|
use Friendica\Util\XML;
|
||||||
|
|
||||||
|
@ -957,7 +958,7 @@ class Feed
|
||||||
XML::addElement($doc, $root, "id", DI::baseUrl() . "/profile/" . $owner["nick"]);
|
XML::addElement($doc, $root, "id", DI::baseUrl() . "/profile/" . $owner["nick"]);
|
||||||
XML::addElement($doc, $root, "title", $title);
|
XML::addElement($doc, $root, "title", $title);
|
||||||
XML::addElement($doc, $root, "subtitle", sprintf("Updates from %s on %s", $owner["name"], DI::config()->get('config', 'sitename')));
|
XML::addElement($doc, $root, "subtitle", sprintf("Updates from %s on %s", $owner["name"], DI::config()->get('config', 'sitename')));
|
||||||
XML::addElement($doc, $root, "logo", $owner["photo"]);
|
XML::addElement($doc, $root, "logo", Contact::getAvatarUrlForId($owner['id'], Proxy::SIZE_SMALL, $owner['updated']));
|
||||||
XML::addElement($doc, $root, "updated", DateTimeFormat::utcNow(DateTimeFormat::ATOM));
|
XML::addElement($doc, $root, "updated", DateTimeFormat::utcNow(DateTimeFormat::ATOM));
|
||||||
|
|
||||||
$author = self::addAuthor($doc, $owner);
|
$author = self::addAuthor($doc, $owner);
|
||||||
|
|
|
@ -1427,18 +1427,18 @@ class OStatus
|
||||||
$attributes = [
|
$attributes = [
|
||||||
"rel" => "avatar",
|
"rel" => "avatar",
|
||||||
"type" => "image/jpeg", // To-Do?
|
"type" => "image/jpeg", // To-Do?
|
||||||
"media:width" => 300,
|
"media:width" => ProxyUtils::SIZE_SMALL,
|
||||||
"media:height" => 300,
|
"media:height" => ProxyUtils::SIZE_SMALL,
|
||||||
"href" => $owner["photo"]];
|
"href" => Contact::getAvatarUrlForId($owner['id'], ProxyUtils::SIZE_SMALL, $owner['updated'])];
|
||||||
XML::addElement($doc, $author, "link", "", $attributes);
|
XML::addElement($doc, $author, "link", "", $attributes);
|
||||||
|
|
||||||
if (isset($owner["thumb"])) {
|
if (isset($owner["thumb"])) {
|
||||||
$attributes = [
|
$attributes = [
|
||||||
"rel" => "avatar",
|
"rel" => "avatar",
|
||||||
"type" => "image/jpeg", // To-Do?
|
"type" => "image/jpeg", // To-Do?
|
||||||
"media:width" => 80,
|
"media:width" => ProxyUtils::PIXEL_THUMB,
|
||||||
"media:height" => 80,
|
"media:height" => ProxyUtils::PIXEL_THUMB,
|
||||||
"href" => $owner["thumb"]];
|
"href" => Contact::getAvatarUrlForId($owner['id'], ProxyUtils::SIZE_THUMB, $owner['updated'])];
|
||||||
XML::addElement($doc, $author, "link", "", $attributes);
|
XML::addElement($doc, $author, "link", "", $attributes);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue