• Resolved cprotz

    (@cprotz)


    Hi

    First a thank you for the plugin that does exactly what I need.

    I created a kind of a internal news aggregation site which fetches and tags news. Mostly over RSS or, where a source does not offer RSS but newsletters, I subscribed to newsletters in mail form (with postie).

    Usually such newsletters have an “unsubscribe” section at the bottom, which I want to delete (or else on of my internal users can unsubscribe us accidentally). While I found the explanation and link to the regular expression site I still struggle in successfully defining the necessary filter in the Postie signature patters section.

    For better reading purpose I had to use html newsletters and a typical code section looks like that:

    <td style=”font-size: 16px; line-height: 22px;” valign=”top”><span
    style=”font-size: medium; line-height: 22px; font-weight: bold; color:
    #333333;”>Sie m?chten keinen Newsletter mehr erhalten?</span>
    <span style=”font-size: medium; line-height: 22px; color: #333333;”><a
    style=”color: #003c8e; text-decoration: none;” href=”https://fuw.us4.list-manage.com/unsubscribe?u=ea21608872ef538d66872fda2&id=5811b63fd6&e=f43669b1b5&c=e16f3d
    ce9e”>Newsletter abmelden</span></td>
    </tr>
    Translation
    “Sie m?chten keinen Newsletter mehr erhalten” ->you don’t want to receive a newsletter anymore
    “Newsletter abmelden” ->Unsubscribe Newsletter

    What part of the code should I use for the filtering in which form?

    Best regards from Switzerland
    Christoph

    https://www.ads-software.com/plugins/postie/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Wayne Allen

    (@wayneallen-1)

    I would use the “Test for message end” setting and put “Sie m?chten keinen Newsletter mehr erhalten?” in the setting.

    Thread Starter cprotz

    (@cprotz)

    Hi Wayne
    Thank you for your reply.

    If I understand the examples in the manual and your tip well, I can do this setting only once (for the newsletter(s) that use this wording).
    Currently I receive newsletters from 150-20 different sources and they use different sentences/words for the unsubscribe section.

    Therefore I once tried it in the signature pattern section, however I guess I did not understand the concept of correctly creating regular expression patterns in there, I used:

    –\s?[\r\n]?
    –\s


    Newsletter abbestellen
    Copyright
    Abmelden
    Editieren
    abbestellen
    Profil
    unsubscribe
    ?

    All the German words in the list are equivalents of unsubscribe or words/signs before the unsubscribe link.

    Plugin Author Wayne Allen

    (@wayneallen-1)

    Please forward one or 2 newletter emails to [email protected] then leave a note here and I will take a look.

    Thread Starter cprotz

    (@cprotz)

    Thank you.

    I just sent two different newsletters:
    WG: finewsletter vom 07.05.2015
    WG: FuW-Newsletter Freitag, 8.5.2015:

    One problem I discovered with the html newsletters is that you can not just cut off without properly closing e.g. tables, else it influences the design of the WP post page. Especially the FuW Newsletter needs html as it looks very strange in the plane text mode (long url links, loss of overview, etc.)

    Plugin Author Wayne Allen

    (@wayneallen-1)

    One problem I discovered with the html newsletters is that you can not just cut off without properly closing e.g. tables, else it influences the design of the WP post page.

    Yes this is an issue. I can imagine a function that looks for the keyword then removes any text from subsequent html elements while leaving the structure in place, but it isn’t a simple task.

    You could also create Postie AddOns that are specific to each newsletter the remove the bits you don’t want.

    I also noticed that finews.ch has an RSS feed at https://www.finews.ch/?format=feed&type=rss and I’m pretty sure there are plugins that will monitor a RSS feed and post the articles. However, fuw.ch doen’t seem to have a feed.

    Thread Starter cprotz

    (@cprotz)

    OK,thank you I’ll check the AddOns, I haven’t looked into that yet.

    The problem with some of the RSS streams, amongst them finews.ch, is that they seem to use some non-standard code which the MultiImporter plugin I use for RSS can not process. I process around 95% of the resources from RSS feeds (currently around 60 feeds) with MultiImporter and the rest via Postie.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Signature patterns filtering’ is closed to new replies.