Not work on search results from Google's home page
![]() ![]() |
Hi Ziru, I find this script does not work on result pages returned by searching right from Google's home page. These pages have addresses like 'http://www.google.com/webhp?...' Could you check it? Thank you very much! |
![]() ![]() |
Hi yugushen, The link you pasted here is not complete. Can you please paste a complete one? Btw, the latest script works for me. Thanks, |
![]() ![]() |
For some reason it isn't working for me either. Here is an example: http://www.google.com/#hl=en&source=hp&q=dog&aq... |
![]() ![]() |
@hstrub hmmm, weird. the link you sent works for me. Can you help check the error console (Tools->Error Console) to see whether any errors reported there? Btw, can you provide a little more information such as the version of GreaseMonkey & FF you installed? Thanks, |
![]() ![]() |
I guess I found the issue, though I could not reproduce it. For me, the google search URL always looks like http://www.google.*/search?*. In order to prevent the script from running on pages like http://www.google.com/support, I added some URL checking in the script before. Unfortunately, it seems like some users are receiving search results via URLs like http://www.google.com/webhp?* or http://www.google.com/#*. I updated the script with relaxed URL checking. Hope the new script will work for you guys. |
![]() ![]() |
Unfortunately, the script is still not working for me. I'm using the latest versions of both GreaseMonkey (0.8.20090123.1) and Firefox (3.5.2). |
![]() ![]() |
I'm not seeing anything in the Error Console related to your script or Google Search. |
![]() ![]() |
@hsrstud Hmmm, I don't really know what caused this. One last way is to save the source of the google search page and share it somewhere (+ the URL), if you don't mind the trouble. |
![]() ![]() |
Download link: http://rapidshare.com/files/271579601/www.googl... Download link: http://rapidshare.com/files/271579600/dog_-_Goo... Download link: http://rapidshare.com/files/271579599/google.js Download link: http://rapidshare.com/files/271579598/search |
![]() ![]() |
Hopefully, this should be everything you need. |
![]() ![]() |
@hsrstud Great. Thanks for sharing the page source. I could now reproduce the issue, and work out the fix. Please try the latest script and let me know if it works this time. |
![]() ![]() |
@Ziru Thank you for keeping working on it. While the latest script still doesn't solve the problem, I find several other scripts, which also modify Google's search result page, doesn't work on those URLs too. I further find three warnings related to Google's own script on these pages: Warning: Selector expected. Ruleset ignored due to bad selector.
Warning: Selector expected. Ruleset ignored due to bad selector.
Warning: Unexpected end of file while searching for closing } of invalid rule set.
So I guess maybe your script is correct, but there's something wrong with Google's script. I'm not familiar with JavaScript, so I cannot figure out what the problem is about Line 6 of Google's script. One more thing, I only get these URLs on Firefox. For IE and Google Chrome, the search page URL is normal, like " |
![]() ![]() |
@yugushen Likely. The old script will not work with the page source shared by @hsrstud, but the new one should (well, i used a local web server to serve that page, and it worked; not 100% sure about the real scenario). Google seems to serve different page layouts to users from different locations. It would be helpful if you could share the page source. |
![]() ![]() |
Unfortunately, it's still not working for me. |
![]() ![]() |
Hi Ziru, Thx for this really nice script. Right now i'm having the same problem as hsrstud.
There are 2 scenarios: 1. It works perfectly because i do a search from the integrated search bar in firefox. The search will happen on www.google.be
2. In the second scenario your script will not work
I set www.google.be (belgium) as my homepage. Although it is the same as in the built in
The search will always start with the url www.google.be/#
Your script doesn't work whenever google replaces the traditional url form
Hope this can help you to make this script fully working again. |
![]() ![]() |
Hi, this problem is caused by Google's new AJAX search results, which are sometimes (and increasingly) used instead of the traditional search. I'm trying to work out how to get around it, but they're doing something really clever / weird. I can set a timeout to check for a DOM object to be present, but it's never present, even though you can see it in the generated source. I'm interested in the solution if someone more clever than me (and Google) can work it out. |
![]() ![]() |
Actually, I may have come up with a solution. Will test it out with my script (not released yet) and if it works, I'll let you know how it works. |
![]() ![]() |
Did you ever get it to work? |
![]() ![]() |
Interested in reading the discussion. I am sorry of being little help on this, since I could not reproduce the issue you guys saw. Let us hope Stephen's solution will work. |
![]() ![]() |
@Stephen Did you get it to work? We're waiting :)
|
![]() ![]() |
I guess this userstyle has similar functionality, just keep the piece that creates the columns. http://userstyles.org/styles/18639 To be exact: @namespace url(http://www.w3.org/1999/xhtml);
|
![]() ![]() |
Finally, the script begins to be broken for me as well when searching at google.com. It turns out that Google starts to use AJAX to show search results. I will fix this issue to make the script working again. |
![]() ![]() |
Thanks, Ziru. The latest script finally solve the problem. Great work. I think this thread can be closed now. |
![]() ![]() |
It took so long for me to reproduce the issue. Anyway, it is great to hear it finally got solved. |




