Prevent adding URLs to history
Moderators: FranklinDM, Lootyhoof
-
adoxa
- Astronaut

- Posts: 705
- Joined: 2019-03-16, 13:26
- Location: Qld, Aus.
Prevent adding URLs to history
I would like to prevent certain URLs being added to history. CAA has "No History" (by Tito Bouzout), but I'm unable to download it. Would someone be able to attach it, or suggest an alternative? TIA.
-
_yuyu_
- Lunatic

- Posts: 267
- Joined: 2015-03-02, 14:18
Re: Prevent adding URLs to history
Pale Moon 64-bit on Win 7 x64
-
adoxa
- Astronaut

- Posts: 705
- Joined: 2019-03-16, 13:26
- Location: Qld, Aus.
Re: Prevent adding URLs to history
No, that doesn't look specific enough (and I use "History disable button 0.4.1-signed.1-let-fixed.1-signed" to toggle history).
-
Enobarbous
- Fanatic

- Posts: 122
- Joined: 2022-12-06, 17:44
Re: Prevent adding URLs to history
Here. Didn't check how efficient it is
You do not have the required permissions to view the files attached to this post.
I am sorry for the use of auto-translator to post
-
adoxa
- Astronaut

- Posts: 705
- Joined: 2019-03-16, 13:26
- Location: Qld, Aus.
Re: Prevent adding URLs to history
Thank you! I'll have a play with it tomorrow. BTW, both files are identical.
-
Moonchild
- Project founder

- Posts: 39714
- Joined: 2011-08-28, 17:27
- Location: Sweden
Re: Prevent adding URLs to history
If you can't get it to work, you can always just use a new private window to go to the sites you don't want stored in history. That is precisely what private browsing is for.
"Sales hates anything that can't be turned into a confident sentence." - anonymous warehouse worker
"Why debate someone you fundamentally don't trust?" - Dario Amodei
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite
"Why debate someone you fundamentally don't trust?" - Dario Amodei
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite
-
adoxa
- Astronaut

- Posts: 705
- Joined: 2019-03-16, 13:26
- Location: Qld, Aus.
Re: Prevent adding URLs to history
It works. The use case is to prevent "supplemental" URLs being added to history, such as this site's "unread&sid" and Cloudflare's "__cf".
-
moonbat
- Knows the dark side

- Posts: 5916
- Joined: 2015-12-09, 15:45
Re: Prevent adding URLs to history
My extension PermisionsPlus allows for this - you can prevent a given domain from being saved to history. Link in my sig.
"One hosts to look them up, one DNS to find them and in the darkness BIND them."

KDE Neon on a Slimbook Excalibur (Ryzen 7 8845HS, 64 GB RAM)
AutoPageColor|PermissionsPlus|PMPlayer|Pure URL|RecordRewind|TextFX
Jabber: moonbat@hot-chili.net

KDE Neon on a Slimbook Excalibur (Ryzen 7 8845HS, 64 GB RAM)
AutoPageColor|PermissionsPlus|PMPlayer|Pure URL|RecordRewind|TextFX
Jabber: moonbat@hot-chili.net
-
adoxa
- Astronaut

- Posts: 705
- Joined: 2019-03-16, 13:26
- Location: Qld, Aus.
Re: Prevent adding URLs to history
I'm really not connecting with people on this. I don't want to block domains, I only want to block specific URLs. E.g. if an.example.url/some/page is behind Cloudflare it's redirected to an.example.url/some/page?__cf_chl... and that's what I want to block, keeping the original.
-
moonbat
- Knows the dark side

- Posts: 5916
- Joined: 2015-12-09, 15:45
Re: Prevent adding URLs to history
You want to remove the cloudflare parameters? Pure URL to the rescue, again in my sig 
"One hosts to look them up, one DNS to find them and in the darkness BIND them."

KDE Neon on a Slimbook Excalibur (Ryzen 7 8845HS, 64 GB RAM)
AutoPageColor|PermissionsPlus|PMPlayer|Pure URL|RecordRewind|TextFX
Jabber: moonbat@hot-chili.net

KDE Neon on a Slimbook Excalibur (Ryzen 7 8845HS, 64 GB RAM)
AutoPageColor|PermissionsPlus|PMPlayer|Pure URL|RecordRewind|TextFX
Jabber: moonbat@hot-chili.net
-
Enobarbous
- Fanatic

- Posts: 122
- Joined: 2022-12-06, 17:44
Re: Prevent adding URLs to history
Can I suggest a different approach? Essentially, given the task, you don't necessarily need to "prevent adding urls to history"; it's enough to simply automatically remove some urls from history. And that's much easier to achieve.
Example code for custom buttons, simply removing some sites from history when closing any tab:
Code: Select all
var deletedSites = ['https://example.com', 'https://example2.com', 'https://example3.com'];
function deleteHistory() {
for (var i = 0; i < deletedSites.length; i++) {
var site = deletedSites[i];
var uri = NetUtil.newURI(site);
PlacesUtils.history.removePage(uri);
console.log(site + ' deleted from history')
}
}
gBrowser.tabContainer.addEventListener('TabClose', deleteHistory, false);
Of course, this isn't a finished solution, but I know you've written at least one extension
I am sorry for the use of auto-translator to post