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

linux_learner

ok, I tried this, and ended up with;
QuoteWarning: main(RSS.php): failed to open stream: No such file or directory in /home/*****/public_html/phpBB2/injector/news.php on line 34

Warning: main(RSS.php): failed to open stream: No such file or directory in /home/*****/public_html/phpBB2/injector/news.php on line 34

Warning: main(RSS.php): failed to open stream: No such file or directory in /home/*****/public_html/phpBB2/injector/news.php on line 34

Fatal error: main(): Failed opening required 'RSS.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/*****/public_html/phpBB2/injector/news.php on line 34



require 'RSS.php';







/** DATABASE Configuration */



define("DB_HOSTNAME","localhost"); //Insert your DB server name here



define("DB_USERNAME","********"); //DB username here



define("DB_PASSWD","******"); // DB password here



define("DB_DATABASE","smf"); //DB name here



$userid = 15; //Set this to the SMF userid you want the messages posted from



$boardid = 87;//Set this to the id of the board you want to post the messages in







/** pull list of remote RSS feeds, via a remote RSS feed. */



$rss_feed = & new XML_RSS('http://microsoft.weblogsinc.com/rss.xml'); //Insert your URL here


linux_learner

ok, I figured out a bit more on my own, and now I just have;
QuoteAccess denied for user: '*******_@localhost' (Using password: YES)

spun2u

Quote from: linux_learner on April 08, 2006, 08:15:06 PM
ok, I figured out a bit more on my own, and now I just have;
QuoteAccess denied for user: '*******_@localhost' (Using password: YES)

This looks like you have an incorrect login. Either username or password.

The injector is working fine on my forum hxxp:forums.u2torrents.com [nonactive]

linux_learner

now i have
QuoteTable 'goofynut_smf.messages' doesn't exist

TechnoDragon

okay, the issue i see (and it has been a problem for everyone) is in the news.php file you seed to manually change it so that all the table refrences have your db prefix in them
Don't tell me to get into shape...I have a shape...It is round!


linux_learner

Quote from: technodragon73 on April 08, 2006, 10:12:55 PM
okay, the issue i see (and it has been a problem for everyone) is in the news.php file you seed to manually change it so that all the table refrences have your db prefix in them


ok, i posted my code previously. can you give me an example of what you mean? i don't quite get you.

linux_learner

got it. took another browse through this thread, and solved it. ( i read this thread like for times  ::) :o )

linux_learner

now can someone tell me how to do different feeds under different catagories?

TechnoDragon

Quote from: linux_learner on April 08, 2006, 11:59:07 PM
got it. took another browse through this thread, and solved it. ( i read this thread like for times  ::) :o )

I'll need to see the entire code to be able to show you...you only posted the top part of it.

Quote from: linux_learner on April 09, 2006, 12:37:01 AM
now can someone tell me how to do different feeds under different catagories?

just change the board id and create a different news.php file...they do not have to be named news.php, could even be xbox.php or anything.
Don't tell me to get into shape...I have a shape...It is round!


linux_learner

Thanks. I have it all done now. Just one last question, does this program automatically import the news every so often? Or do I need to refresh each one everyso often?

TechnoDragon

you have to either manually run the php file to import the news, or use a cron job to run it for you
Don't tell me to get into shape...I have a shape...It is round!


linux_learner

ok. I have never done a cron job before. Whats the command that I would use?

TechnoDragon

Quote from: linux_learner on April 09, 2006, 11:15:11 AM
ok. I have never done a cron job before. Whats the command that I would use?

Typically in simple mode you just paste the path to the file...

something like /home/www/yourdomain/news.php

you can get the server path from the server settings in smf
Don't tell me to get into shape...I have a shape...It is round!


linux_learner

Either the file isnt pulling in news, or, theres no news on the server, or the command doesn't work. In any case, I dont seem to be getting any new news from any of my source, whether i manually refresh or not.

TechnoDragon

the code was written in a way to make sure it did not repost the same news...so it is possible that there is no new news to pull.
Don't tell me to get into shape...I have a shape...It is round!


starrbuck

Quote from: technodragon73 on April 04, 2006, 09:31:57 PM
potentially if you are any good at coding you could create a php file that would run all of your news feed php files.  Then set a cron job to run that file.  I just haven't figured out a way to do it yet.

You could also make it parameter-driven so that you pass in the URL each time you run the script.  Would not be hard to implement.

kilokat7

Thanks to the instructions in this thread, the script is working nice for me.  I have one request now that I've played with it.  I'm interested in injecting one RSS feed that consists of 5-8 topics.  Since this is a short feed, I would like all 5-8 topics to appear in one single post on my forum as opposed to 5-8 individual posts.  Any clues on how to hack the code to achieve this?  I'm referring to the "news.php" code...

JamieinNH

OK,   I still have a problem with this not working for some reason.

I have done a couple of tests and think maybe it's something to do with my host.

I installed SMF on Host A, ran the script and everything worked like a charm.

I installed SMF on Host B, ran the script and got nothing.   I got a blank page, but no results.


So, I know the script works on one host, FutureQuest, but it doesn't work on the second host DreamHost.

Anyone have any ideas as to why it would work on one host, but not another?


Thanks for any suggestions.

Jamie

Xarcell

I also use dreamhost, and this script doesn't work for me either. I'm beaten my head against the wall trying to figure it out. If you figure it out, please let me know.

Dreamhost is a great host, but it isn't SMF friendly...

SEO

#139
Dreamhost is a terrible host for things like the rssbot
It will probably be an fsock problem and you will need to redo the code to get it to work.
PLay Online Poker and chat in our Poker Forum

Advertisement: