Are you enjoying the extensions? Did you like the support? Help others decide.

Leave a review

file Newsfeed plugin troubles

More
3 years 8 months ago #5406 by teddyfresco
Newsfeed plugin troubles was created by teddyfresco
Hi Olivier, I've setup locally LNEP with newsfeed plugin to import a RSS feed (which I copy below), and it works great with title and text, but I've got some issues:
1) I'm trying to display the "newspaper" part, can you guide me to some useful doc or have you got any hint?
2) I've added under Info tab and info block which collects author, and it works, but strangely it displays whole "no journalist", but it trims "Adam Never" to just "Never" (same for others)  and I didn't set any parameter to cut it...
3) Titles with " are displayed like this, not with " ", is there any setting to do it?
Thanks and regards,

<?xml version="1.0" encoding="UTF-8"?>
<rss version="0.91">
    <channel>
        <title>Sport RSS</title>
        <description>NCAA Sports</description>
        <link>www.sportsncaaa.it
        <language>it</language>
        <item>
            <id>1423</id>
            <title>
                <![CDATA[What to Watch in the &quot;First Weekend&quot;]]>
            </title>
            <description>
                <![CDATA[The 2021 N.C.A.A. men’s basketball tournament tipped off Thursday with the play-in games from Indiana. They included a late-night matchup of the blue bloods U.C.L.A. and Michigan State, winners of a combined 13 national championships, but the action tips off in earnest on Friday.]]>
            </description>
            <pubDate>03/18/2021</pubDate>
            <newspaper>
                <![CDATA[Washington Post]]>
            </newspaper>
            <author>
                <![CDATA[ no journalist]]>
            </author>
            <link>www.sportsncaaa.it/articoli/20210203t10_001.pdf
        </item>
        <item>
            <id>1403</id>
            <title>
                <![CDATA[Gonzaga begins its quest for history]]>
            </title>
            <description>
                <![CDATA[The second-round games this year will occur on Sunday and Monday (feel free to call in sick on Monday), and by Monday night, the round of 16 will be set.]]>
            </description>
            <pubDate>03/12/2021</pubDate>
            <newspaper>
                <![CDATA[New York Times]]>
            </newspaper>
            <author>
                <![CDATA[ Adam Never]]>
            </author>
            <link>www.sportsncaaa.it/articoli/20210312_p001.pdf
        </item>

Please Log in or Create an account to join the conversation.

More
3 years 8 months ago #5407 by syw
Replied by syw on topic Newsfeed plugin troubles
Hello Teddy,

here are my answers:

1 - 'newspaper' does not appear to be  a 'standard' tag for RSS 2.0 and this information is not picked up by the Newsfeeds plugin. I don't have a solution for you here other than modifying the plugin to fit your need.

2 - That's strange. I'll do some tests with the feed on my end. The author name should remain unchanged.

3 - I will make an adjustment in the plugin so that the quotes are properly displayed.

I will get back to you later with my finding. This answer is just an initial review of the problems you are having.

Olivier.

Please Log in or Create an account to join the conversation.

More
3 years 8 months ago #5408 by syw
Replied by syw on topic Newsfeed plugin troubles
Just an additional question:
are you the originator of the feed? sportsncaaa.it does not seem to exist.
I would need the feeds URL if possible.

Olivier.

Please Log in or Create an account to join the conversation.

More
3 years 8 months ago - 3 years 8 months ago #5409 by syw
Replied by syw on topic Newsfeed plugin troubles
No answer?

Anyway, back to mine:

1 - there will be no support for the 'newspaper' element. It is definitely not standard. 
However, if you are the originator of the feed, you could use the standard <source> element. It needs a 'url' attribute and the content of the tag is text. So you could add, for every item:

<source url="https://newspapersite.com">The Newspaper Site</source> 

I have added support for the <source> element in the plugin. I have included a layout that allows the selection of that information in Latest News Enhanced Pro.

2 - I have improved on Joomla's treatment of the <author> element. This will better deal with any content: email address followed by author name or email address only or author name only.

3 - Quotes are now properly dealt with in item titles.

All these and more will be available in version 5.1.1 of the plugin. 

Olivier.
Last edit: 3 years 8 months ago by syw.

Please Log in or Create an account to join the conversation.

More
4 months 2 days ago - 4 months 1 day ago #6095 by teddyfresco
Replied by teddyfresco on topic Newsfeed plugin troubles
Hi Olivier, sorry, for some reason I didn't check your answer, very rude by me, but I don't remember the reason. Better late then never, please excuse me.
In the meantime LNEP evolved a lot and it is getting better and better!! I'm also trying to improve my translation, I keep finding items in need for reviews...
To solve the problem with the <newspaper> non standard element I've tried using my details plugin and this tutorial:
simplifyyourweb.com/documentation/tutori...st-news-enhanced-pro
But it didn't work... maybe if you show me the file where I can add the code for this newspaper element I can try to code by myself?
the rss feed is this one, maybe it give you another hint:
www.testurl.com/rss.asp
Best regards
Last edit: 4 months 1 day ago by teddyfresco. Reason: cloak url

Please Log in or Create an account to join the conversation.

More
4 months 2 days ago #6098 by syw
Replied by syw on topic Newsfeed plugin troubles
No worries, Teddy.

Like previously stated, the <newspaper> tag does not seem to be standard so it is not supported and therefore not parsed by Newsfeeds.

This is why you cannot retrieve the information through the tutorial. The output does not contain any notion of newspaper.

To support it, you would have to code a specific parser in the plugin itself.

Olivier.

Please Log in or Create an account to join the conversation.