Userscripts
Userscripts copied to clipboard
[Google YouTube search link] No longer working after Google's latest update
Please ensure:
- [X] I included in the issue title the script name I'm referring to.
- [X] I performed a search of the issue tracker and in the relevant Greasyfork feedback page to avoid opening a duplicate issue.
- [X] The bug is caused by the script itself. It doesn't happen if I disable the script, or in a fresh browser profile.
Include in this issue:
- [X] Screenshots/video/gif demonstrating the bug, if it’s visual
- [ ] Console errors, if any
Describe the problem and how to replicate it
Google has been changing how their search pages look and the latest version unfortunately breaks this script. They are slowly unveiling the new look, so some people may still be seeing the old one. The new version looks like this:
Example URL
https://www.google.com/search?q=test
Script Manager
Violentmonkey
Browser(s) used
Chrome 111
Thanks for letting me know. 👍
I still have the old layout so the script is still working fine for me:
When the new look rolls out for me I'll update the script.
I've gone ahead and made a new script from scratch which adds buttons for several different searches next to Google's search form. I'm not putting it on a userscripts site because frankly I don't have time to deal with support. You're free to copy it or parts of it if you want. I don't know for sure if it would work on the older version of Google. Maybe it would be cool to have an options window where people could easily change the buttons around. So yeah, use it or don't, and thanks for maintaining the other script!
Of course within hours of me posting that to Pastebin, Google decided to change their search box to a textarea (after 25 years of it being an input), thus breaking the script. Anyway, it's working again now.
I've gone ahead and made a new script from scratch which adds buttons for several different searches next to Google's search form. I'm not putting it on a userscripts site because frankly I don't have time to deal with support.
I really like this format: elegant & efficient use of space.
(This is a shoutout to everyone, who ever can assist!)
I'ld like to add a Button to use GSearch for 'site' searches: e.g. I'm trying to make one for HN, but the following formats are not working--
'Search URLs':
'https://www.google.com/', 'search?site%3Anews.ycombinator.com&q='
'search?q=%s+site%3Anews.ycombinator.com'
'search?+site%3Anews.ycombinator.com&q='
'search?complete=0&site%3Anews.ycombinator.com&q='
Then moved 'search?' over to 'Domains', tried:
'https://www.google.com/search?', 'complete=0&site%3Anews.ycombinator.com&q=', 'https://news.ycombinator.com/favicon.ico'
Still no-go. In all cases, the links open a gsearch page with just the vale of 'q=' in the textbox.
I'ld like to add a Button to use GSearch for 'site' searches: e.g. I'm trying to make one for HN, but the following formats are not working--
To do site searches, try this:
'https://www.google.com/', 'search?q=site:news.ycombinator.com '
Include that space at the end. You don't have to worry about using stuff like "%3A" since the script will do that itself.
And to search HN directly, you can do:
'https://hn.algolia.com/', '?q='
To do site searches, try this:
'https://www.google.com/', 'search?q=site:news.ycombinator.com '
Include that space at the end. You don't have to worry about using stuff like "%3A" since the script will do that itself.
Thank you! That works perfectly.
I'm also converting the favicons to base64 embeds -- the calls to the sites' urls every page load are too annoying & inefficient.
@lednerg Eventually I got the new layout:
Unfortunately the buttons no longer have icons (as in the screenshot in your OP).
You see, I was relying to the Google's 'Videos' SVG icon:
in order to identify the relevant 'Videos' node for the various Google localizations. That's unfortunately no longer possible.
So, I have deleted the script from Greasyfork. When/if I find a solution I'll update and restore it. I'm always open for PR of course.
Side note:
the buttons now are displayed in two steps, not all at once, e.g. initially:
and then as in my former screenshot. This also complicates things.
@darkred I think video search links always have &tbm=vid. So you could probably use something like: document.querySelectorAll('a[href*="&tbm=vid"]')