Advertisement:

Author Topic: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds  (Read 670920 times)

Offline Study Force

  • SMF Hero
  • ******
  • Posts: 3,329
    • StudyForcePS on Facebook
    • @studyforceps on Twitter
    • Study Force
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #520 on: August 23, 2016, 01:20:03 AM »
Yeah, there's still multiple better ways of doing it than that, such as using SSI.php to do it (and that doesn't even need hacking anything about), you can call SSI.php?ssi_function= and one of the names of the functions in that file, which is ready formatted for HTML.

SMF in iframes is still not clever though at least the normal security protocol won't get in your way there.

Didn't know you could do this

Offline uamsameter

  • Semi-Newbie
  • *
  • Posts: 81
    • A Students Notebook
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #521 on: August 23, 2016, 01:53:42 PM »
Hello people,
I'd like to know if there's a way to allow rss feeds create a new topic automatically in my forum... I saw somewhere that there's a mod for it but I can't find it. Thanks.

Still waiting for help on my earlier request too.
Hi,
I just got my rss feed on twitter and it seems to be tweeting every single post (all replies). I'm worried that it may become a headache for my followers in the long run.
Is there a way to show just new topics and nothing more?

Eagerly anticipating your reply.
Thanks
Wandering is free. Certainty has a price.

Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 69,299
    • StoryBB/StoryBB on GitHub
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #522 on: August 23, 2016, 02:00:45 PM »
The first post in this thread outlines how you do it, put ;sa=news in the URL...
Don’t try to tell me that some power can corrupt a person. You haven’t had enough to know what it’s like.

No good deed goes unpunished / No act of charity goes unresented.

Offline uamsameter

  • Semi-Newbie
  • *
  • Posts: 81
    • A Students Notebook
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #523 on: August 23, 2016, 03:29:21 PM »
Okay thanks. I will try it out.

Any help about my other request?
Like if I want to automatically get a topic created for every post at my blog or other website, can I set it via rss feeds?
Wandering is free. Certainty has a price.

Offline Kindred

  • The Mean One
  • Support Specialist
  • SMF Legend
  • *
  • Posts: 57,098
  • Gender: Male
    • Kindred-999 on GitHub
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #524 on: August 23, 2016, 03:43:36 PM »
no.

there is no external post feature in SMF.
There are two RSS-feed-importers mods, however
Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

Offline uamsameter

  • Semi-Newbie
  • *
  • Posts: 81
    • A Students Notebook
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #525 on: August 23, 2016, 04:10:26 PM »
Hi kindred, please give me links to the mods. Thanks.
Wandering is free. Certainty has a price.

Offline Kindred

  • The Mean One
  • Support Specialist
  • SMF Legend
  • *
  • Posts: 57,098
  • Gender: Male
    • Kindred-999 on GitHub
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #526 on: August 23, 2016, 04:13:11 PM »
I suggest you learn how to use search....

however, because I have a moment:
http://custom.simplemachines.org/mods/index.php?mod=624
http://custom.simplemachines.org/mods/index.php?mod=1590
Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

Offline uamsameter

  • Semi-Newbie
  • *
  • Posts: 81
    • A Students Notebook
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #527 on: August 23, 2016, 04:32:24 PM »
I searched before asking. Didn't find nothing.
Thanks anyway.
Wandering is free. Certainty has a price.

Offline Kindred

  • The Mean One
  • Support Specialist
  • SMF Legend
  • *
  • Posts: 57,098
  • Gender: Male
    • Kindred-999 on GitHub
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #528 on: August 23, 2016, 05:37:14 PM »
you went to the mod site and searched on "RSS"?   that's where those two came from...
Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

Offline uamsameter

  • Semi-Newbie
  • *
  • Posts: 81
    • A Students Notebook
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #529 on: August 23, 2016, 05:43:13 PM »
Oh, i did it differently. Searched the forum instead.
I just learnt how to use search. Lol
Wandering is free. Certainty has a price.

Offline KirkhamsEbooks

  • Jr. Member
  • **
  • Posts: 281
Aloha old topic I know sorry,

I'm using SMF 2.0.13 . Is there an rss feed for search results. I'm working on a search page. I can filter, but if I don't have to do any extra coding that would be great.

Rick

Offline Illori

  • Project Manager
  • SMF Master
  • *
  • Posts: 49,841
no there is not.

Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 69,299
    • StoryBB/StoryBB on GitHub
Having a system repeatedly hit your server, every few minutes, to do one of the most expensive operations in SMF doesn't seem all that healthy for your server.
Don’t try to tell me that some power can corrupt a person. You haven’t had enough to know what it’s like.

No good deed goes unpunished / No act of charity goes unresented.

Offline Study Force

  • SMF Hero
  • ******
  • Posts: 3,329
    • StudyForcePS on Facebook
    • @studyforceps on Twitter
    • Study Force
Having a system repeatedly hit your server, every few minutes, to do one of the most expensive operations in SMF doesn't seem all that healthy for your server.

This post is in reference to whom?

Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 69,299
    • StoryBB/StoryBB on GitHub
It was in reference to KirkhamsEBooks, wanting to get an RSS feed on searching as searching is one of the most expensive operations one can do on an unmodified SMF (it's up there with unread and unread replies)
Don’t try to tell me that some power can corrupt a person. You haven’t had enough to know what it’s like.

No good deed goes unpunished / No act of charity goes unresented.

Offline Study Force

  • SMF Hero
  • ******
  • Posts: 3,329
    • StudyForcePS on Facebook
    • @studyforceps on Twitter
    • Study Force
True

A better way would be to create an index every time a search is conducted into a database table. Then call it out where it is needed.

Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 69,299
    • StoryBB/StoryBB on GitHub
Except that doesn't fix the case he's talking about, where the feed would update over time. Consider what a feed of 'searching for "help"' would look like - every time a new topic comes up that has that word in it, a new feed item would appear.

It's definitely possible to build the functionality, but it needs to be very carefully thought about - I've done it on some of the stuff I build professionally but that's not forum based, and the search feed was built very specifically for that one purpose. Doing it and still keeping it fast is a real challenge.
Don’t try to tell me that some power can corrupt a person. You haven’t had enough to know what it’s like.

No good deed goes unpunished / No act of charity goes unresented.

Offline Study Force

  • SMF Hero
  • ******
  • Posts: 3,329
    • StudyForcePS on Facebook
    • @studyforceps on Twitter
    • Study Force
And not to be presumptions, but I don't think a small forum would require such functionality

Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 69,299
    • StoryBB/StoryBB on GitHub
His use case does make sense, somewhat.
Don’t try to tell me that some power can corrupt a person. You haven’t had enough to know what it’s like.

No good deed goes unpunished / No act of charity goes unresented.

Offline Dwev

  • Jr. Member
  • **
  • Posts: 217
Re: Getting the Most Out of SMF - XML, RSS and RSS2 (and Atom and RDF) feeds
« Reply #539 on: March 18, 2018, 11:20:56 AM »
In case someone is looking for the same solution as I was (and because it took me weeks to find the solution), hereby the solution that I finally found.

I wanted a RRS Feed that shows only the titles of the topics, but with the topic that had the most recent reaction always showing up on the top of the list.

I used the following format in the feed: https://www.xxxxxx.xx/index.php?action=.xml;sa=news;board=22;limit=5;type=rss2
and this reaction from 'Elhcay' put me on the right track, but the description wasn't that clear.

If you want the same, you'll have to edit in /Sources/News.php the following:

Find:
Code: [Select]
ORDER BY t.id_first_msg DESC
Replace with:
Code: [Select]
ORDER BY t.id_last_msg DESC
That's all...   ;)


I do still have a wish though, the date that shows up in front is the date if the original post, while I would like to see the date of the last reaction.