MozillaZine

Remove senders' repeated signatures when replying

User Help for Mozilla Thunderbird
bugcsilla
 
Posts: 3
Joined: January 10th, 2020, 6:06 am

Post Posted January 10th, 2020, 7:22 am

Some folks attach the same signature with every reply. This can make mails very long and difficult to read.
Is there a way to remove these ugly beasts automatically?

nytram made a similar point a while ago
viewtopic.php?f=30&t=220981

tanstaafl
Moderator

User avatar
 
Posts: 46215
Joined: July 30th, 2003, 5:06 pm

Post Posted January 10th, 2020, 8:51 am

I'm not aware of an add-on that does what you want. The closest would be to use the add signature add-on that lets you add a signature by right clicking in the message body to add the signature, and do that only when sending. You would use that rather than have Thunderbird automatically add a signature due to the accounts settings.

Another solution would be to not specify a signature in the accounts settings and compose new messages using a template that has the signature. Since you wouldn't use a template to reply, you wouldn't need to worry about adding additional signatures as a side effect.

You can create message filters for sending. Usually that is done just to specify a different location to save a copy of your sent mail but another solution would be to create a message filter that appends a signature just when sending a new message. That would require you to install the Filtaquilla add-on and probably write some javascript. See http://quickfilters.mozdev.org/filtaquilla.html

Each of those solutions don't remove the signature, they avoid it being added in the first place by changing how it is normally added. Off hand I can't think of a way to automatically remove an already added signature other than with a send message filter that parses the message body and edits it (which is more work than only adding it when sending) , programming some function key using the keyconfig add-on to run a script to edit the draft and then send the file, or use a window macro recorder such as AutoIt or TinyTask.

morat
 
Posts: 3636
Joined: February 3rd, 2009, 6:29 pm

Post Posted January 10th, 2020, 9:27 am

I can hide the footer in a company's newsletters using the userContent.css file.

Code: Select all
/* Thunderbird userContent.css */

@-moz-document url-prefix("imap:"), url-prefix("mailbox:"), url-prefix("news:") {
  .footer {
    /* background-color: orange !important; */
    display: none !important;
  }
}

http://kb.mozillazine.org/UserContent.css

If the CSS selector is too broad, then you may hide something you don't want to.

CSS Reference
http://developer.mozilla.org/en/CSS_Reference
http://developer.mozilla.org/en/CSS_Reference/Mozilla_Extensions

morat
 
Posts: 3636
Joined: February 3rd, 2009, 6:29 pm

Post Posted January 10th, 2020, 11:14 am

Here is a similar tweak using the userChromeJS extension.

* <profile>\chrome\userChrome.js

Code: Select all
/* Thunderbird userChrome.js */

(function () {

  if (location == "chrome://messenger/content/messenger.xul") {
    setTimeout(function () {
      try {
        var browser = document.getElementById("messagepane");
        browser.addEventListener("load", function () {
          var win = content;
          var title = win.document.title;
       // console.log(title);
          if (title.startsWith("Acme Corporation Newsletter")) {
            var footer = win.document.querySelector(".footer");
         // footer.style.backgroundColor = "orange";
            footer.style.display = "none";
          }
        }, true);
      } catch (e) {
        Components.utils.reportError(e);
      };
    }, 1000);
  }

})();

userChromeJS by jikamens
http://addons.thunderbird.net/thunderbird/addon/986610

Instructions:

1. install userChromeJS extension
2. close email client
3. create or edit the userChrome.js file in the chrome folder
4. open email client

You do not need to purge the caches with jikamens' version.

userChromeJS by alta88 (obsolete)
http://userchromejs.mozdev.org/
http://userchromejs.mozdev.org/faq.html

I like the js method more than the css method since I can use the message subject to restrict the style.
Last edited by morat on January 10th, 2020, 11:20 am, edited 1 time in total.

makaiguy

User avatar
 
Posts: 16815
Joined: November 18th, 2002, 6:44 pm
Location: Somewhere in SE USA

Post Posted January 10th, 2020, 11:18 am

tanstaafl wrote:I'm not aware of an add-on that does what you want. The closest would be to use the add signature add-on that lets you add a signature by right clicking in the message body to add the signature, and do that only when sending. You would use that rather than have Thunderbird automatically add a signature due to the accounts settings....

I think the poster is asking about removing the sigs in RECEIVED messages. Some of these, especially from corporate accounts, can be excessively long. In a string of replies-to-replies-to-replies this can get downright ridiculous.
Doug Wilson, "The Makai Guy"
Win10 (64bit): FF 73.0.1 (64bit), TB 68.4.2 (32-bit) ║ Android 8.0/7.1.1: FF Mobile 68.5.0, No TB for Android available, dammit!
What a fool believes he sees, no wise man has the power to reason away - Doobie Brothers

JYLD
 
Posts: 188
Joined: July 18th, 2019, 9:59 am

Post Posted January 10th, 2020, 4:01 pm

The answer to this problem is the addon "Nested Quote Remover". Its one of my must have addons, and one of the reasons I'm still using TB 60.9.1.

https://addons.thunderbird.net/en-US/th ... m-seufert/

It allows you to select how many layers of nested quotes you want to maintain when you reply in a long email chain. By cutting off the nested quotes in replies you cut off the nested quotes when your reply is then replied to.

I don't believe it is available for TB 68+

tanstaafl
Moderator

User avatar
 
Posts: 46215
Joined: July 30th, 2003, 5:06 pm

Post Posted January 10th, 2020, 5:07 pm

http://mozext.achimonline.de/nestedquot ... wnload.php claims it supports versions 61.* - 70.* though the preceding page talks about "Bringing the extensions back to life would require a complete rewrite using WebExtensions." Only one way to find out if it works with 68.

morat
 
Posts: 3636
Joined: February 3rd, 2009, 6:29 pm

Post Posted January 10th, 2020, 6:54 pm

I can install NestedQuote Remover in Thunderbird 68 and feature 1 through 3 works here.

1. compose window > Options menu > NestedQuote Remover menu > Remove nested quotes menuitem
2. compose window > Options menu > NestedQuote Remover menu > Options menuitem
3. compose window > Quotes toolbarbutton

NestedQuote Remover uses the groupbox and caption elements. (may cause a problem in options.xul dialog)

Changes in Thunderbird 61-68
http://developer.thunderbird.net/add-ons/tb68/changes

bugcsilla
 
Posts: 3
Joined: January 10th, 2020, 6:06 am

Post Posted February 6th, 2020, 12:02 pm

Thanks for all your thoughts. Corporate quotes and signatures are useful, but can be outright evil when used without thought. They can be longer than the actual message.

I see several types.

A) DISCLAIMER
________________________________
This e-mail may contain privileged blabla
________________________________

B) VIRUS-ADS
---------------------------------------------------------------------------------------
This email has been scanned blabl
billscanner.com
------------------------------------------------------------------------------------------

C) SIGNATURE

I could not find a consistent pattern with which they are encapsulated. What are the official rules?

Idea for an AddON to 1) select the evil snippets with the mouse and then have a NUKEIT button that deletes identical instances within the email. This AddOn could keep a database of evil snippets and offer to delete them without selection the next time. Any thoughts?

JYLD
 
Posts: 188
Joined: July 18th, 2019, 9:59 am

Post Posted February 6th, 2020, 2:43 pm

You should try the nested quote remover program. Its automatic behind the surface in its operation. Manual intervention isn't required. You just set the level of nested quotes to keep, and that's it. I set it to 2 levels deep, so nested quotes in levels 3 and up are deleted automatically whenever I reply to a message.

bugcsilla
 
Posts: 3
Joined: January 10th, 2020, 6:06 am

Post Posted February 6th, 2020, 2:56 pm

Tks for the tip. But the nested quote remover will also remove the earlier part of the email discussion, which I often need to keep.

JYLD
 
Posts: 188
Joined: July 18th, 2019, 9:59 am

Post Posted February 7th, 2020, 4:13 pm

The earlier part of the discussion will be in the earlier emails. So it isn't lost.

Return to Thunderbird Support


Who is online

Users browsing this forum: Bruce L. and 2 guests