Send URL we publish
Webmention and Pingback both need the exact URL we are going to claim to link to to be present in our HTML source, so send them our actual original link. Webmention clients are supposed to resolve this link. Pingback clients may still fail on shortened links.
This commit is contained in:
parent
3b1792c8b5
commit
d9d74ca96c
@ -107,11 +107,15 @@ class LinkbackPlugin extends Plugin
|
|||||||
|
|
||||||
$wm = $this->getWebmention($result);
|
$wm = $this->getWebmention($result);
|
||||||
if(!empty($wm)) {
|
if(!empty($wm)) {
|
||||||
$this->webmention($result->final_url, $wm);
|
// It is the webmention receiver's job to resolve source
|
||||||
|
// Ref: https://github.com/converspace/webmention/issues/43
|
||||||
|
$this->webmention($url, $wm);
|
||||||
} else {
|
} else {
|
||||||
$pb = $this->getPingback($result);
|
$pb = $this->getPingback($result);
|
||||||
if (!empty($pb)) {
|
if (!empty($pb)) {
|
||||||
$this->pingback($result->final_url, $pb);
|
// Pingback still looks for exact URL in our source, so we
|
||||||
|
// must send what we have
|
||||||
|
$this->pingback($url, $pb);
|
||||||
} else {
|
} else {
|
||||||
$tb = $this->getTrackback($result);
|
$tb = $this->getTrackback($result);
|
||||||
if (!empty($tb)) {
|
if (!empty($tb)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user