| View previous topic :: View next topic |
| Author |
Message |
tommytom Voice
Joined: 09 Sep 2011 Posts: 16
|
Posted: Fri Sep 09, 2011 8:42 am Post subject: fixes |
|
|
http://pastebin.com/ePrDhySD
I can't tell what all I have done to it.
I fix things, other things break.
No telling what all is working still.
Today, however, I changed a few things I CAN tell you what I did and what works that I tested.
-Changed the UA to presto (Opera) for testing/future-compatibility reasons (if you don't like Opera, I don't suggest you change it willy-nilly, but instead use Fiddler with the Request Builder using the URL+UA and view the WebView and/or read the source in the program or copy/paste into an editor like notepad++) and the fact that Google now refuses to supply "Lynx" (browser itself or the UA) with the "onebox" special results. No surprise really, because Lynx doesn't show images, but they could have at least gave a text form....
-Modified define: to work with new UA (or maybe it's been broken a while, I dunno), give a working link, and simplified the RegEx (won't break as bad, I presume)
-Fixed the "finance" currency results to return a clickable link and EXTREMELY shorter (build a custom URL instead of take it RAW)
-Fixed image search to work with the DRASTICALLY different source that gets fed to the new UA (it's no longer plain text but a crapload of JS too)
-Weather (and anything with "onebox") has been fixed (several times over the months).
Tested and working:
Weather, define:, spell:, conversions (measurements), currency (finance), image search (might have added !gi, don't recall), google fight
Untested and probably broken:
News, anything with maps (area code, travel), anything not using "onebox" in the category matching (the image URL has changed much over the months, but onebox seems to be the recent/working constant), video (but I think it works), books
Keep in mind that this is a personal script, but with the lynx crap and the source changing when you change the UA, I knew that 100% of the bots using this script are probably broken. So, that said, don't be surprised if you find some hackish fixes in here I never meant to be public or stable. I probably used .*? where I should have use .+?, but it shouldn't be a problem (sorry, I put some REALLY old mods in this thing when I was learning TCL, eggdrop, AND RegEx).
Edit:
The base script is 1.8.8g
I think that's the lastest official release, but I have been adding my own code and never seen any updates, so I just hacked it up how I see fit without checking for updates. Sorry if there is a better base script out there that I could have based my changes on. |
|
| Back to top |
|
 |
Trixar_za Op

Joined: 18 Nov 2009 Posts: 143 Location: South Africa
|
Posted: Fri Sep 09, 2011 12:23 pm Post subject: Re: fixes |
|
|
| tommytom wrote: | The base script is 1.8.8g
I think that's the lastest official release, but I have been adding my own code and never seen any updates, so I just hacked it up how I see fit without checking for updates. Sorry if there is a better base script out there that I could have based my changes on. | That's the version done by madwoota and the one you find in the egghelp script repository, but it's NOT the version we're using here. This is the unofficial fork created by speechles and the difference is several features and about 6000 extra lines of code, comments and configuration options. Go to the first page and click the download link for this version  _________________ http://www.trixarian.net/Projects |
|
| Back to top |
|
 |
speechles Revered One

Joined: 26 Aug 2006 Posts: 1398 Location: emerald triangle, california (coastal redwoods)
|
Posted: Fri Sep 09, 2011 12:34 pm Post subject: Re: fixes |
|
|
| tommytom wrote: | The base script is 1.8.8g
I think that's the lastest official release, but I have been adding my own code and never seen any updates, so I just hacked it up how I see fit without checking for updates. Sorry if there is a better base script out there that I could have based my changes on. |
Differences between 1.8.8 and 2.0.0:
The script below, is the one supported, 1.8.8 hasn't been supported for some time.
Incith:Google v2.0.0c
My fork of the incith-google project allows for people of any language to use the script, and have it output in their natural language. The 1.8.8g version is stuck in one language only. The unofficial version also, supports wikipedia, ebay, gamespot, gamefaqs, etc, etc ... Now while some things within the unofficial are presently broken those will be corrected when I have the time. Until then, if you want to help with the incith-google project, use the currently supported version.. which is the unofficial...
PROTIP: The shortcoming... | Code: | # make sure we have something to send
if {[info exists output] == 0} {
set reply "Sorry, no search results were found."
if {[info exists did_you_mean] == 1} {
append reply " Did you mean: ${did_you_mean}?"
}
return $reply
} |
It's creating it's own "script generated" output using English. So that one language supported, you guessed it.. Only English. This isn't his fault. This is the original way Incith/Madwoota had it. This way is quite limited and annoying for those who aren't english as their first language. See below how it should work when no results are found, or there is a did you mean.
Top two up there contain "did you mean". Notice the one in Spanish? Notice as well the "no results" message in full Dutch. Displaying "exactly" as it would on google. This is how it should be done.
Therefore, the fixes created to fix the "one boxes" within 1.8.8 will not work for the unofficial 2.0.0 version I have. The scraping templates cannot be bound to English words found in text. They change when you change languages. They must be framed around html elements that build the page. These remain the same no matter which language is used. This is much harder to accomplish and have it work in any language. Call it challenging..  _________________ speechles' eggdrop tcl archive
Last edited by speechles on Fri Sep 09, 2011 1:40 pm; edited 3 times in total |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Fri Sep 09, 2011 1:15 pm Post subject: |
|
|
Moderated: These posts have been split from the thread UNOFFICIAL incith-google 2.0.0c (Sep9,2o11)
as this is a fork of incith-google 1.8.8g, and not Speechles' fork.
/NML_375 _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|