vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   RSS News Feed Hack (https://vborg.vbsupport.ru/showthread.php?t=60899)

redlabour 04-11-2004 03:52 PM

Sorry - me again :

Did i understand your rigtht @Slapyo - with your changes to the Code this Hack is automatically posting new News from the Feeds without deleting the new ones ?

Or is it overwriting the old ones ?

And is there a option to delete one of my Feeds in the AdminCP ?

Slapyo 04-11-2004 05:03 PM

@vau7 ... my changes were to the rss_update.php and functions_newpost.php, that's it. i think the original coder had changes in other files. here is the post that includes the file that i downloaded and have been working with.

https://vborg.vbsupport.ru/showpost....&postcount=139

when i get home tonight i will throw together a package that will include everything that i have done and give the install. it will be a complete package.

just the code i have shown will not work just by itself. you have to have everything else installed properly. see the link i posted for the files that i used to install.

@rockergrrl ... that should work actually. i noticed you have 2 $rss_descriptions for each one. i think that's my fault for some code i posted for you. this should work because when inserting the data it uses the url tags to make the link.

PHP Code:

// change <b> tags
$rss_title str_replace("<b>""[b]"$rss_title);
$rss_description str_replace("</b>""[/b]"$rss_description);

// change <i> tags
$rss_title str_replace("<i>""[i]"$rss_title);
$rss_description str_replace("</i>""[/i]"$rss_description); 

@redlabour ... my changes in code only change the way the actual post is made. instead of manually inserting the post (original), my code uses vB's built in function to insert the post enabling searching, similiar threads, and correct post counts.

if you installed the code properly there is a link in the admincp to HACKS which has RSS News Bot under that. you can add, edit, or delete a bot. if you don't want to delete it, you can just turn it off. however, this is all part of the original code. i make no changes to the way the bot collects the data, or admincp changes, just how the data is posted.

rockergrrl 04-11-2004 05:25 PM

Oy....

Can't get it to work.. even updated threads... no go... :ermm:

I can't ge the &nbsp problem fixed either.....

And then changing the bold and italics tags it puts ".&lt;br&gt;&lt;i&gt;" in the posts. :ermm:

Thanks again for all your help, I greatly appreciate it!

Screens...

redlabour 04-11-2004 05:30 PM

@Slapyo - no in the Admin CP you can only edit the Feeds - there is no "Delete" Funktion.

And sorry - i have to ask again (i know i have written it a little bit confusing before !) :

If the Hack is working correctly does the robot post the News and overwrite them if there are new ones or does he add all of them - means old and new News. I can?t know it by now because it did only worked one time with no more update of the News. ;)
Can somebody tell me this ? (Sorry - my english is a little bit untrained - i work on it again ! ;)

Slapyo 04-11-2004 06:33 PM

oh, ok i though there was a way to delete a bot in there...wasn't sure.

the way it works is this. when the bot grabs the news it will check all the news articles. if there is a new one, it will skip that news article. sometimes i have noticed that with Yahoo! news i get repeated titles, but the content of the article is different, so they are different posts. but it should not repeat an article, it will just goto the next one.

new news, will be new posts and the old news will be kept, no posts are deleted. but no repeat posts should be made.

redlabour 04-11-2004 06:51 PM

That was something i understand no definitely !! ;) Thanx ...

Slapyo 04-11-2004 10:36 PM

ok, here it is. i just ran it on my server and it worked fine. there are a couple things...

1 - might be a cleaner/neater way to convert the ASCII to normal characters
2 - might not convert all the ASCII to normal characters

so you may end up with like &apos; or &nbsp; or &#010 .... whatever it may be ... if someone wants to look at the code and see if they could clean it up that would be great. that code is in /includes/RSS/rss_update.php ... it's towards the bottom.

i have it running on my forums that i just started up ... you can see it here, http://www.sportsbabble.net

Host Visions 04-12-2004 12:33 AM

if anyone would help me get these RSS feeds running on my vb3 I will gladly pay you funds via paypal! If interested, please PM me here.

mirdin 04-12-2004 05:28 PM

Quote:

Originally Posted by Slapyo
ok, here it is. i just ran it on my server and it worked fine. there are a couple things...

Great work! Thanks!

I have one minor issue though.
I've set the user id in rss_admin, but the threads show a different user id as the poster.

EDIT:
Actually it seems to be a random user id every time the rss feeds are posted...

Slapyo 04-12-2004 06:28 PM

Quote:

Originally Posted by mirdin
Great work! Thanks!

I have one minor issue though.
I've set the user id in rss_admin, but the threads show a different user id as the poster.

EDIT:
Actually it seems to be a random user id every time the rss feeds are posted...

my problem use to be that it would post the news as whoever the person was that triggered the cron script. but i fixed that, and have had other users, and visitors trigger the script and it always posts as my bot.

after thinking about your problem some, it sounds like the problem that i had before. did you make the changes in your functions_newpost.php? it should change the build_new_post function and then change the global variables just below that in the function.


All times are GMT. The time now is 01:12 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01373 seconds
  • Memory Usage 1,751KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete