forked from blallo/rss-bridge
[Wikipedia] Use entire entry as title for 'Did you know'
This commit is contained in:
parent
04b4dd1db9
commit
1cfb8c02a0
1 changed files with 3 additions and 1 deletions
|
@ -191,8 +191,10 @@ class WikipediaBridge extends BridgeAbstract{
|
||||||
private function AddDidYouKnowGeneric($element, $fullArticle){
|
private function AddDidYouKnowGeneric($element, $fullArticle){
|
||||||
foreach($element->find('ul', 0)->find('li') as $entry){
|
foreach($element->find('ul', 0)->find('li') as $entry){
|
||||||
$item = new \Item();
|
$item = new \Item();
|
||||||
|
|
||||||
|
// We can only use the first anchor, there is no way of finding the 'correct' one if there are multiple
|
||||||
$item->uri = $this->uri . $entry->find('a', 0)->href;
|
$item->uri = $this->uri . $entry->find('a', 0)->href;
|
||||||
$item->title = $entry->find('a', 0)->title;
|
$item->title = strip_tags($entry->innertext);
|
||||||
|
|
||||||
if(!$fullArticle)
|
if(!$fullArticle)
|
||||||
$item->content = $this->ReplaceURIInHTMLElement($entry);
|
$item->content = $this->ReplaceURIInHTMLElement($entry);
|
||||||
|
|
Loading…
Reference in a new issue