Advertisement:

Author Topic: RSS Feeder  (Read 375333 times)

Offline hartiberlin

  • Full Member
  • ***
  • Posts: 679
  • Gender: Male
    • overunity.com the International free energy research forum
Re: RSS Feeder
« Reply #840 on: December 01, 2009, 09:01:42 PM »
If I put for instance at:
http://www.travelhotelscheap.com/regex.php

Code: [Select]
~<div id="articlestory">(.*)<\/div>~siUinto the regex: form
what should I put into the
body: form ?

The whole body of the HTML page ?

So when I press then submit, what should it display ?

Only the extracted text of the webpage as the article or
still some HTML code with the array [1] statement around it ?

What about the
Code: [Select]
array [0] statement that also is there and has parts
of the article I wish to extract ?
« Last Edit: December 01, 2009, 09:04:49 PM by hartiberlin »

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,276
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
Re: RSS Feeder
« Reply #841 on: December 01, 2009, 09:14:12 PM »
You can't use the regex from my tutorial... that's why it's a tutorial, to show you how to create your own regex based on the HTML from your page.

Yes, the 'body' box gets the HTML, the regex box gets the regular expression.
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline UndergroundChic

  • Semi-Newbie
  • *
  • Posts: 29
Re: RSS Feeder
« Reply #842 on: December 02, 2009, 12:26:15 AM »


Undergroundchic - You could modify the add_settings.php script and remove {db_prefix} anywhere in the file, then modify package-info.xml and change the 'install for' line to 2.0 RC1.2.  I would recommend upgrading SMF though.

Thank You SD  :P

Offline hartiberlin

  • Full Member
  • ***
  • Posts: 679
  • Gender: Male
    • overunity.com the International free energy research forum
Re: RSS Feeder
« Reply #843 on: December 02, 2009, 12:25:47 PM »
the regex box gets the regular expression.

What does this exactly mean ?

What is a " regular expression" in this case ?

Please can you show it exactly on an example from any
RSS feed page please ?

Many thanks in advance and thanks again for your hard work !

Offline juliegreen

  • Semi-Newbie
  • *
  • Posts: 62
    • job seekers
Re: RSS Feeder
« Reply #844 on: December 02, 2009, 06:15:22 PM »
Post Feed As=
Enter who you would like this topic posted as.


what do i need to write for the field Post Feed As? i tried many thing but nothing works. could give an example to write?

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,276
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
Re: RSS Feeder
« Reply #845 on: December 02, 2009, 06:24:06 PM »
you have to use an existing user on your board, like your username, or create a new user named 'Bot', and type it's name in there.
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline juliegreen

  • Semi-Newbie
  • *
  • Posts: 62
    • job seekers
Re: RSS Feeder
« Reply #846 on: December 02, 2009, 06:32:47 PM »
thank you SlammedDime,

i was just confused the forums and tried the username which wasn't in the forum im using your mod.

thanks again.

Offline juliegreen

  • Semi-Newbie
  • *
  • Posts: 62
    • job seekers
Re: RSS Feeder
« Reply #847 on: December 03, 2009, 10:56:18 AM »
there are two links in the feeds and i understand the source link but how can i remove the title link? and maybe place a nofollow attr. to source link?

thank you

Offline hartiberlin

  • Full Member
  • ***
  • Posts: 679
  • Gender: Male
    • overunity.com the International free energy research forum
Re: RSS Feeder
« Reply #848 on: December 04, 2009, 04:42:45 PM »
Are there no more comments to my last questions ?

Please how can we get this better done with the regex thing.
I need a good example, so I can understand this better.

Many thanks in advance.

Regards, Stefan.

Offline GreenMotion

  • Semi-Newbie
  • *
  • Posts: 22
Re: RSS Feeder
« Reply #849 on: December 04, 2009, 05:57:00 PM »
Quick Question here,

How does this tool determine whether or not a RSS feed item has already been posted or not?  What does it check for to make this determination?

Thank you,

   GM

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,276
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
Re: RSS Feeder
« Reply #850 on: December 04, 2009, 07:35:33 PM »
Stefan - can you point out exactly what from my tutorial you don't understand, then I might be able to better help you out.

GreenMotion - For every feed posted, it calculates an MD5 sum of the title of the item and stores it in the database for 30 days.  The log is pruned on a regular basis and items older than 30 days are discarded (to keep down on database size).
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline GreenMotion

  • Semi-Newbie
  • *
  • Posts: 22
Re: RSS Feeder
« Reply #851 on: December 04, 2009, 09:18:48 PM »
Thanks SlammedDime.

I got confused for a bit because it wouldn't update the RSS posts but after some googling and looking through the code I noticed it is caching the RSS feeds for 2 hours which explains a lot.

It would be nice if these cache settings were configurable through the configuration screen.

    GM

Offline hartiberlin

  • Full Member
  • ***
  • Posts: 679
  • Gender: Male
    • overunity.com the International free energy research forum
Re: RSS Feeder
« Reply #852 on: December 05, 2009, 05:48:15 AM »
Hi SlammedDime,
how could I extract the FULL articles for instance from this RSS feed:

http://www.asiatraveltips.com/travelnews.xml

What must I set for the REGEX there and how would I find it ?

Many thanks in advance.

Regards,Stefan.


Offline hartiberlin

  • Full Member
  • ***
  • Posts: 679
  • Gender: Male
    • overunity.com the International free energy research forum
Re: RSS Feeder
« Reply #853 on: December 05, 2009, 09:05:21 AM »
Hi,
as there was no div tag
that started the articles in:

http://www.asiatraveltips.com/travelnews.xml

I used the following
regex code:

Code: [Select]
~<\/script><\/div>(.*)<br>~siU
Now it extracts the articles,
but as soon as inside the article there is an apostrophe like this for example
Code: [Select]
ship´s cabin

the RSS text does stop after the word
ship
and is no further extracted...

How could that be avoided ?

Many thanks.
« Last Edit: December 05, 2009, 09:10:45 AM by hartiberlin »

Offline hartiberlin

  • Full Member
  • ***
  • Posts: 679
  • Gender: Male
    • overunity.com the International free energy research forum
Re: RSS Feeder
« Reply #854 on: December 05, 2009, 10:42:06 AM »
Another question.

How can I disable the link at the top of the imported posting to the
original article ?

Many thanks.

Offline frymaster

  • Newbie
  • *
  • Posts: 4
Re: RSS Feeder
« Reply #855 on: December 05, 2009, 12:03:28 PM »
Stefan - can you point out exactly what from my tutorial you don't understand, then I might be able to better help you out.

GreenMotion - For every feed posted, it calculates an MD5 sum of the title of the item and stores it in the database for 30 days.  The log is pruned on a regular basis and items older than 30 days are discarded (to keep down on database size).

does this mean that with the feed I have (which has every article ever posted since the blog was created) that after 30 days it will post old articles again?

Offline hartiberlin

  • Full Member
  • ***
  • Posts: 679
  • Gender: Male
    • overunity.com the International free energy research forum
Re: RSS Feeder
« Reply #856 on: December 05, 2009, 12:17:18 PM »
Also the character:

Code: [Select]
stops the import of the full text.

How could that be avoided ?

Many thanks.

Offline SlammedDime

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 10,276
  • School of Air Ride
    • matt.zuba on Facebook
    • @mattzuba on Twitter
Re: RSS Feeder
« Reply #857 on: December 05, 2009, 12:25:49 PM »
Stefan, I'm heading out the door now, but I'll take a look at your feed when I get back later this afternoon.  To answer your other questions: You'd have to open ScheduledTasks.php and scroll down to the bottom and find the bit that puts the whole post together and edit that.  In a future version of the mod, I'll create user editable templates for posting feeds.  As for the quote mark, I'll have to test it locally to see why that happens.

frymaster - yes.  Typically, RSS feeds would contain the latest and greatest items from a blog or site, rarely do they contain all items since inception.  You can change the length of time of pruning in the Pruning Options admin panel... just set the number of days to something high and it'll never be pruned... keep in mind though that if you have multiple feeds, none of them will ever be pruned and that log table can grow very large in size depending on how many items are posted.
SlammedDime
Former Lead Customizer
BitBucket Projects
GeekStorage.com Hosting
                      My Mods
SimpleSEF
Ajax Quick Reply
Sitemap
more...
                     

Offline hartiberlin

  • Full Member
  • ***
  • Posts: 679
  • Gender: Male
    • overunity.com the International free energy research forum
Re: RSS Feeder
« Reply #858 on: December 05, 2009, 12:40:01 PM »
Hi.

I am trying to suppress the quote mark and apostrophe signs,
with:

Code: [Select]
~<\/script><\/div>(.*['"])<br>~siU
but that did not work...
What is the regex code  to supress these signs.. ?

Many thanks.

Offline hartiberlin

  • Full Member
  • ***
  • Posts: 679
  • Gender: Male
    • overunity.com the International free energy research forum
Re: RSS Feeder
« Reply #859 on: December 07, 2009, 04:27:10 PM »
Hmm,
it seems some RSS Feeds are just not very compatible or are wrong programmed, so
also RSS-Feeder can not retrieve it.

I found now another RSS Feed that works with the REGEX code I used.


2. How can I change the Header of the posting, so that the domain name
is not displayed, where the feed is pulled from ?

Also I would like to have an option to disable the
"Source:"
at  the bottom of the postings.

How could that be done ?

Must I hack the RSS-Feeder php files for this or will you soon
include an option to disable it ?

Many thanks.