News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

RSS Injector available

Started by confusion, December 24, 2005, 04:04:48 PM

Previous topic - Next topic

TLM

By all means, I have little time right now to program/script anymore.

* TLM passes the torch on...

Veign

OK.  I will get the code and SQL to build the table up on my server in the morning and post a link here - going to sleep now.

Thanx for all the work you put into it!

KGIII

I have a slight request or three...

Let us say we pull the requests from WordPress...

1) A URL inside the post isn't pulled - just the text is.
2) If it is already tagged AND you're using the tag system MOD with SMF - can those tags be pulled into the same system?
3) I think that is it BUT it was easy enough for me to do, even easy to setup the CRON jobs. For some it may not be so simple. Is it POSSIBLE to set a 4 hour CRON and/or admin control panel for that?
4) They pull 'em in backwards. A blog post made at 10:00 will show up on the top of a blog post made at 10:05... Buggered if I can figure it out.

That's all I can think of with it.

My PC Support Forum
Please ask in-thread before PMing
                   SMF Help
                   Visit My Blog

How can we improve the support process?:
http://www.simplemachines.org/community/index.php?topic=163533.0

SMF vs. Godzilla? Who do you think will win?

KGIII

Oh, crap, multiple feeds in a single file... That'd be nice too.

My PC Support Forum
Please ask in-thread before PMing
                   SMF Help
                   Visit My Blog

How can we improve the support process?:
http://www.simplemachines.org/community/index.php?topic=163533.0

SMF vs. Godzilla? Who do you think will win?

L.G.S

Quote from: Veign on December 23, 2006, 12:57:04 AM
I don't want to step on anyone's toes but I have a modified version that:
- Uses SimplePie as the feed parser
- Pulls requested feeds from a DB table (feed url, board id, member id)
- Uses some very basic configuration settings in the php file to control the look of the post

If anyone is interested in this I will upload to my server so you can check it out (have it).  If this steps on the toe's of TLM than I didn't mean to and will not make another post on this subject.



Sounds great, could I test it ???
FREE and LIVE World Cup + Premier League football streams:

www.gamesandgoals.com


TLM

Quote from: KGIII on December 23, 2006, 02:45:46 AM
I have a slight request or three...

Let us say we pull the requests from WordPress...

1) A URL inside the post isn't pulled - just the text is.
2) If it is already tagged AND you're using the tag system MOD with SMF - can those tags be pulled into the same system?
3) I think that is it BUT it was easy enough for me to do, even easy to setup the CRON jobs. For some it may not be so simple. Is it POSSIBLE to set a 4 hour CRON and/or admin control panel for that?
4) They pull 'em in backwards. A blog post made at 10:00 will show up on the top of a blog post made at 10:05... Buggered if I can figure it out.

That's all I can think of with it.
Quote from: KGIII on December 23, 2006, 02:46:10 AM
Oh, crap, multiple feeds in a single file... That'd be nice too.
1) Example of this occuring?
2) Huh?  tag system mod?
3) Im sorry I am hard ass, if you cant figure out how to setup a cron job, tough cookies...
4) I think I fixed this, for most feeds unless your feed unfixes this...

5) Uh... Have you not bothered to setup my script?  Multiple feeds via sql....




Quote from: L.G.S on December 23, 2006, 06:17:27 AM
Sounds great, could I test it ???

Your answer....

Quote from: TLM on December 23, 2006, 01:07:20 AM
By all means, I have little time right now to program/script anymore.

* TLM passes the torch on...
Quote from: Veign on December 23, 2006, 01:15:30 AM
OK.  I will get the code and SQL to build the table up on my server in the morning and post a link here - going to sleep now.

Thanx for all the work you put into it!

Veign

#346
I posted the code to:
hxxp:www.veign.com/vrc_codeview.asp?type=web&id=47 [nonactive]

Sample board where its working:
hxxp:www.scarymind.com/index.php?board=26.0 [nonactive]

Improvements that I need to make:
- Add the date/time stamp back to the DB when a feed was last retrieved (very easy to do just need to do it)

Veign

Quote from: TLM on December 23, 2006, 12:25:45 PM
Quote from: KGIII on December 23, 2006, 02:45:46 AM
I have a slight request or three...

Let us say we pull the requests from WordPress...

1) A URL inside the post isn't pulled - just the text is.
2) If it is already tagged AND you're using the tag system MOD with SMF - can those tags be pulled into the same system?
3) I think that is it BUT it was easy enough for me to do, even easy to setup the CRON jobs. For some it may not be so simple. Is it POSSIBLE to set a 4 hour CRON and/or admin control panel for that?
4) They pull 'em in backwards. A blog post made at 10:00 will show up on the top of a blog post made at 10:05... Buggered if I can figure it out.

That's all I can think of with it.
Quote from: KGIII on December 23, 2006, 02:46:10 AM
Oh, crap, multiple feeds in a single file... That'd be nice too.
1) Example of this occuring?
2) Huh?  tag system mod?
3) Im sorry I am hard ass, if you cant figure out how to setup a cron job, tough cookies...
4) I think I fixed this, for most feeds unless your feed unfixes this...

5) Uh... Have you not bothered to setup my script?  Multiple feeds via sql....




Quote from: L.G.S on December 23, 2006, 06:17:27 AM
Sounds great, could I test it ???

Your answer....

Quote from: TLM on December 23, 2006, 01:07:20 AM
By all means, I have little time right now to program/script anymore.

* TLM passes the torch on...
Quote from: Veign on December 23, 2006, 01:15:30 AM
OK.  I will get the code and SQL to build the table up on my server in the morning and post a link here - going to sleep now.

Thanx for all the work you put into it!

TLM pretty much answered everything.   

Also, note I was never able to download TLM's version so I grabbed an earlier version that used SimplePie Feed parser and modified it to suit my needs.  So far, its works as I need without any known issues.

I will continue to support the script as needed.

KGIII

1. The link in my signature - it pulls blog posts from my blog and puts them in the news.
2. http://mods.simplemachines.org/index.php?mod=579 <-- tagging system
    http://blog.kgiii.info <-- also has tags
3. I suppose but some people might not be able to figure it out. But, as you say, tough cookies.
4 & 5. Hmm... I'll scroll back through and re-read all the posts but I'm pretty sure it is the one that Veign was using with SimplePie and so I don't think I've installed your script, instead I was posting for/to Veign to whom you'd passed the torch on.

I do believe that your's was at a mindlesstux site? If so then when I went to go download it, it was gone.

My PC Support Forum
Please ask in-thread before PMing
                   SMF Help
                   Visit My Blog

How can we improve the support process?:
http://www.simplemachines.org/community/index.php?topic=163533.0

SMF vs. Godzilla? Who do you think will win?

TLM

#349
1) Did not see any specific examples, but running with the problem, some feeds encase the url in html tags.  Could have that disabled, auto linking of urls could also be another factor.  My script I did not see any flaw with this.
ex.  http://www.tpf-guild.com/forum/index.php?topic=622.0

2) Hrm interesting idea, dunno, all the feeds I played with did not have tagging systems...  /me might have something else to do now on tha huge stack of things to look at in free time.

3) Good you see it my way, it helps keep out those that install mods for the sake of installing them.  (I know people that do this and it drives me crazy)

4/5)  Yeah I moved it and forgot to relink it.  I still dont have the sql file remade again but back a few pages someone posted the create table info, just fill in the blanks and set time to 0.
http://www.mindlesstux.com/files/rss_injector.phps

*edit*

--
-- Table structure for table `smf_rssfeeds`
--

DROP TABLE IF EXISTS `smf_rssfeeds`;
CREATE TABLE `smf_rssfeeds` (
  `ID` int(11) NOT NULL default '0',
  `MEMBER_ID` int(11) NOT NULL default '0',
  `BOARD_ID` int(11) NOT NULL default '0',
  `RSS_FEED` text NOT NULL,
  `LAST_UPDATE` int(11) NOT NULL default '0',
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;

--
-- Dumping data for table `smf_rssfeeds`
--


/*!40000 ALTER TABLE `smf_rssfeeds` DISABLE KEYS */;
LOCK TABLES `smf_rssfeeds` WRITE;
INSERT INTO `smf_rssfeeds` VALUES
  (0,1,14,'http://www.guildwars.com/newsarchive/rss/news-current.xml',1166836846),
  (1,1,14,'http://www.guildwars.com/support/gameupdates/rss/updates-current.xml',1166770029),
  (2,1,16,'http://steampowered.com/rss.xml',1166778000);
UNLOCK TABLES;
/*!40000 ALTER TABLE `smf_rssfeeds` ENABLE KEYS */;

The SQL Code for what I have right now on tpfguild.com
*/edit*



Oh Veign,
I just glanced at your code, you might be interested in db_query provided through SSI.php....  Saves a little more work for users to setup things.  See the .phps file linked above that will not move.

Veign

Quote from: TLM on December 23, 2006, 07:08:58 PM
Oh Veign,
I just glanced at your code, you might be interested in db_query provided through SSI.php....  Saves a little more work for users to setup things.  See the .phps file linked above that will not move.

Cool.  Will get this replaced out in the next version - sometime late tonight. 

I need to sit down and look through the Function list for SMF to see if there is anything I can gain from their code.

Veign

Quote from: KGIII on December 23, 2006, 06:51:08 PM
2. http://mods.simplemachines.org/index.php?mod=579 <-- tagging system
    hxxp:blog.kgiii.info [nonactive] <-- also has tags

I will have to look at how / if tags are embedded in the feed and if SimplePie parses them out. I'll check into this.

TLM

Quick glance the tages are under things like subject and catagory.  Now I have no clue as to if simplepie pulls them out.

Veign

Quote from: TLM on December 23, 2006, 08:35:27 PM
Quick glance the tages are under things like subject and catagory.  Now I have no clue as to if simplepie pulls them out.

I can get access to them with SimplePie. 

The problem I have is making RSS Injector dependant, even slightly, on a mod. Also, not sure I want to waste the processing time checking if the mod is installed (not sure there is a simple mechanism for this).  What I would rather do is wait for tags to become part of the core SMF code and then add the functionality.

KGIII

Thanks TLM. I'll take a look at the code later and see what happens.

Here's one such example:

http://forum.kgiii.info/index.php?topic=257.0

(Though it's not your code so I don't expect you to have the answer though, well, you might?)

The line:
Microsoft seeks patent covering Web feed readers | Tech News on ZDNet

Should actually be a link, well it was at the blog...

It was, of course, wrapped in tags and so it only grabbed the text instead of the link.

That and the tagging system is pretty interesting. Getting the two to work together would be a lot like work I suppose.

My PC Support Forum
Please ask in-thread before PMing
                   SMF Help
                   Visit My Blog

How can we improve the support process?:
http://www.simplemachines.org/community/index.php?topic=163533.0

SMF vs. Godzilla? Who do you think will win?

RvG

#355
Quote from: Veign on December 23, 2006, 01:05:09 PM
I posted thde code to:
http://www.veign.com/vrc_codeview.asp?type=web&id=47

Sample board where its working:
http://www.scarymind.com/index.php?board=26.0

Improvements that I need to make:
- Add the date/time stamp back to the DB when a feed was last retrieved (very easy to do just need to do it)
Thanks. :) it works perfectly... i have tried also TLM files but I think I will use this one...  8)

mindiam1

Where is the download for this mod file?

Veign

Did you read through any of the posts in this thread?


dextrous

I tried the zip file instruction...

but here's where I'm stuck (im a n00b!)
3) Run the rss-injector.sql script against your SMF database in MySQL (delete this file
when completed).

What does this mean?? Just requires me to upload file to the smf_forum table?? if so, then why do i have to delete it?

thanks for help.

Advertisement: