This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

stopping old headlines

Help for those learning Tcl or writing their own scripts.
Post Reply
User avatar
NewzNZ
Halfop
Posts: 68
Joined: Thu Mar 05, 2009 5:15 am
Contact:

stopping old headlines

Post by NewzNZ »

Hi there

I have a series of scripts to pull headlines off various sites. To avoid repeating the previous item, each time the bot goes to send a story to the room it checks to see if it was the last story by:

if {($news != $newslast)} {

send to room and set $newslast etc

The problem I'm having with some sites is that if you check them eg every minute, sometimes the freshest story reverts back to the second story for a couple of minutes before coming back again - must be some kind of caching problem on the website.
This kind of thing results:

STORY NEW
STORY 2ND NEWEST
STORY NEW...then it settles out.

Anyway what I'm trying to work out is another check way to avoid sending these previously sent items out again to the room when they've already hit.

Thanks in advance for help!
Post Reply