Author Topic: help needed writing spamstatus plugin  (Read 3840 times)

Offline capncrunch

  • Newbie
  • *
  • Posts: 1
help needed writing spamstatus plugin
« on: November 13, 2012, 11:09:34 AM »
Hi,

I'm trying to create a spamstatus plugin which should accomplish these tasks:

  • flag messages in list view
  • flag messages in message view
  • option to select all flagged messages

This is no take on another local filter plugin, filtering is up to Sieve. What I want to achieve is RC displays an icon on messages that have been marked by SpamAssassin or any other filter.

Alpha code is available at https://github.com/capncrunch/spamstatus. I'm running into a couple of issues here:

  • I have no clue how to add an icon into list view. I could use colors but would prefer an icon.
  • I'm currently displaying an icon in front of the sender in message view but would prefer to display this icon in front of the subject. Problem is RC is HTML escaping the code when I put it in front of the subject field.
  • I added an icon to the listcontrols container manually. I tried using add_button instead but didn't get any output.
  • How do I make the select button to actually select all spam messages? Reading through the source code of RC suggests select-all isn't extendable like this.

This is supposed to be used on a virtual RC farm running on Debian stable so code needs to be compatible with RC 0.3.1 and I can't modify RC itself.

I'd be very grateful if anybody could provide me with a hint to my problems above.

TIA.

Offline mckaygerhard

  • Jr. Member
  • **
  • Posts: 29
Re: help needed writing spamstatus plugin
« Reply #1 on: May 23, 2014, 01:40:07 PM »
this may help:
Code: [Select]
        $skin  = $rcmail->config->get('skin');

        if(!file_exists('plugins/spamstatus/skins/' . $skin . '/images/ham.png')){
          $skin = "default";
        }
and now works with u'r "default/image/*png" fiels..

i let a message in the github proyect