Azzu
The functionality in this script is indeed only possible as an addon or userscript. Browsers specifically spent a lot of work trying to make it impossible for one site to get any information about which other sites the user visited, and for good reason. Just imagine the phishing this would allow if it were possible.
That said, there could of course be an official lemmy browser addon/userscript for this functionality. But it definitely wouldn’t be baked into the sites themselves.
Because idk if you noticed, but this script actually rewrites all links everywhere, so for example even if you get a result to some lemmy instance on duckduckgo, the link on duckduckgo itself will already point to your instance. Please tell me how that would be possible without an addon/userscipt :D
Shameless plug für mein Script, dass Links intern gehen lässt wenn möglich: https://greasyfork.org/en/scripts/469273-lemmy-rewrite-links-to-home-instance
(wenn man eh schon so am Scripts installieren ist)
Wild idea, but could it just be that you’re using it wrong? :D if you’re on lemmy.ca then almost nothing should be rewritten because almost all links already go to lemmy.ca. Only when you go to another instance somehow or a user posts a link, for example this one then it should be rewritten.
Anyway though, here is a debug version of the script: https://gitlab.com/-/snippets/2561468/raw/main/lemmy.user.js
To use, open the browser console, unselect all message types at the top right (errors, warnings, logs…) except for the “Debug” message type, then reload the page and right-click -> send me all messages.
Does it work again when you do a full refresh? So F5/press enter in the adress bar? If so then somehow listening to page changes is broken for you, lemmy doesn’t actually load new pages when you click on an (instance-local) link, it just exchanges all the content within the currently loaded page.
@admin@lemmit.online yeah I don’t know for some reason neither this nor my previous post gets picked up by the bot. Any idea why?