I can see that the url has changed since the script was released - http://grouphug.us to http://beta.grouphug.us currently. I.ve reflected this in the script but still no confessions are displayed but this message:
'[Error] Could not find a confession.'
My coding limit is simple bodging so can someone else suggest or provide a fix for this?
tia
Here is your scraper along with the return of results. What you will need to do is become familiar with regexp and regsub (regexp takes, pulls data from an expression, your scraper; regsub substitutes, replaces data in an expression, cleans up the scrape). The html template (aka, the tags which delineate the text desired) has changed and you must update your template scraper (aka, the regexp's) to accomodate the change. It would be quite easy for me to solve for you if I wasn't in such a hurry.. Hopefully someone can brighten your day before I get back from errands and I won't need to. Just posted to let you know the area you should focus your interest on.
Solved, I found time.
Prior to tcl version 8.3.1 the double-quote was not allowed inside curly braces, which was a bug. Ever since tcl 8.3.1 fixed this, Perplexa's use of escapes to protect double-quotes inside curly braces isn't required anymore. I'm just letting you know this to help you better understand regexp.
Thanks for evaluating the script and replying but I have no idea what I should do to correct the code. I'm not even a tcl novice. The correction you made doesn't appear to be a simple copy & paste swap so I don't know what to do with it. I don't wish to appear ungrateful and appreciate that you want to encourage posters to learn tcl but I really can't commit to studying it atm for one lapsed script. If you could make it a bit easier to grasp that would be great but it might turn into a saga . I contacted perplexa and he says he is waiting for the grouphug site to complete the upgrade before he updates. Thanks again.
shadrach wrote:Thanks for evaluating the script and replying but I have no idea what I should do to correct the code. I'm not even a tcl novice. The correction you made doesn't appear to be a simple copy & paste swap so I don't know what to do with it. I don't wish to appear ungrateful and appreciate that you want to encourage posters to learn tcl but I really can't commit to studying it atm for one lapsed script. If you could make it a bit easier to grasp that would be great but it might turn into a saga . I contacted perplexa and he says he is waiting for the grouphug site to complete the upgrade before he updates. Thanks again.
What is so difficult? Just take each line individually. Load up the whatever.tcl in wordpad. Use replace in the menus (replacing each line individually, because wordpad won't let you do multiple lines at once). The two lines are right next to each other. This is a simple copy & paste swap. Resave the document as TXT type in wordpad, and name it whatever.tcl it was when you opened it. Your making things out harder than they seem.
Speechles, we were both wrong and right. The grouphug script in the tcl archive at this site is different to the one i was using. I probably got it at perplexa's site, http://perplexa.ugug.org/. The lines you highlighted are absent in the more recent script I had. I wasn't aware there was difference, sorry. I just downloaded the older one from the archive here and performed the search and replace successfully -i'm not so stupid . So I've uploaded this revised script to my eggdrop but it still doesn't work. I think the url paths are wrong still and i'm currently messing around with this to see if i can accidentally get it to work. grouphug uses google to search now i think. Yes, I contacted perplexa earlier in the week via his shoutbox but he hasn't posted there since june so I wasn't hopeful of a response.