mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-04-09 16:38:50 +00:00
[FacebookBridge] Removes query string from post links
* [FacebookBridge] Removes query string from post links
This commit is contained in:
parent
37f84196b7
commit
bf30ad127c
@ -430,6 +430,8 @@ EOD;
|
|||||||
|
|
||||||
if(isset($element)) {
|
if(isset($element)) {
|
||||||
|
|
||||||
|
defaultLinkTo($element, self::URI);
|
||||||
|
|
||||||
$author = str_replace(' | Facebook', '', $html->find('title#pageTitle', 0)->innertext);
|
$author = str_replace(' | Facebook', '', $html->find('title#pageTitle', 0)->innertext);
|
||||||
$profilePic = 'https://graph.facebook.com/'
|
$profilePic = 'https://graph.facebook.com/'
|
||||||
. $this->getInput('u')
|
. $this->getInput('u')
|
||||||
@ -536,7 +538,11 @@ EOD;
|
|||||||
if(strlen($title) > 64)
|
if(strlen($title) > 64)
|
||||||
$title = substr($title, 0, strpos(wordwrap($title, 64), "\n")) . '...';
|
$title = substr($title, 0, strpos(wordwrap($title, 64), "\n")) . '...';
|
||||||
|
|
||||||
$uri = self::URI . $post->find('abbr')[0]->parent()->getAttribute('href');
|
$uri = $post->find('abbr')[0]->parent()->getAttribute('href');
|
||||||
|
|
||||||
|
if (false !== strpos($uri, '?')) {
|
||||||
|
$uri = substr($uri, 0, strpos($uri, '?'));
|
||||||
|
}
|
||||||
|
|
||||||
//Build and add final item
|
//Build and add final item
|
||||||
$item['uri'] = htmlspecialchars_decode($uri);
|
$item['uri'] = htmlspecialchars_decode($uri);
|
||||||
|
Loading…
Reference in New Issue
Block a user