+ Reply to Thread
Results 1 to 3 of 3

Thread: PostfixAdmin Vacation plugin (again!?)

  1. #1
    k1piee is offline Roundcube Newcomer
    Join Date
    Jul 2009
    Posts
    8
    Downloads
    3
    Uploads
    0

    Default PostfixAdmin Vacation plugin (again!?)

    Hi!

    I've been searching around for a simple plugin that sort of integrates the Postfixadmin vacation/autoreply in Roundcube.
    I found this: Roundcube and postfixadmin
    But I can't really get it to work properly.. I get an error message every time I try to save the vacation messge, either [internalerror] or just that the message couldn't be saved.

    If I check the database I can see that it doesn't add information to the "domain" and "created" fields. Also, it seems to work fine to save the message a first time, but if I try to update it thats when I get the error messages. And he has modified the vacation.pl script too to add the "active from" and "active to" which for me isn't really necessary to have. Just a simple "Subject","Message" and "Active" will do just like in Postfixadmin.

    I'm no programmer and barely understands PHP, but wouldn't it be kind of simple to just take some code from the Postfixadmin vacation and make a simple plugin for Roundcube? Or is it more than that that has to be done?


    I would really appreciate if someone could help me out here!

    I also found a "postfixadmin to roundcube bridge" but that project was discontinued and doesn't seem to work anymore, and I've been searching around for a good plugin but can't seem to find one that just do the trick..

    Thanks,
    -Patric

  2. #2
    k1piee is offline Roundcube Newcomer
    Join Date
    Jul 2009
    Posts
    8
    Downloads
    3
    Uploads
    0

    Default

    I checked arround a little bit what database modifications Postfixadmin does when vacation/autoreply is activated.

    This is the database "postfix":

    Code:
    +-----------------------+
    | Tables_in_postfix     |
    +-----------------------+
    | admin                 |
    | alias                 |
    | alias_domain          |
    | config                |
    | domain                |
    | domain_admins         |
    | fetchmail             |
    | log                   |
    | mailbox               |
    | quota                 |
    | quota2                |
    | transport             |
    | transport_copyto      |
    | transport_mail        |
    | vacation              |
    | vacation_notification |
    +-----------------------+
    The "alias" table looks like this:

    Code:
    +----------+--------------+------+-----+---------------------+-------+
    | Field    | Type         | Null | Key | Default             | Extra |
    +----------+--------------+------+-----+---------------------+-------+
    | address  | varchar(255) | NO   | PRI | NULL                |       |
    | goto     | text         | NO   |     | NULL                |       |
    | domain   | varchar(255) | NO   | MUL | NULL                |       |
    | created  | datetime     | NO   |     | 0000-00-00 00:00:00 |       |
    | modified | datetime     | NO   |     | 0000-00-00 00:00:00 |       |
    | active   | tinyint(1)   | NO   |     | 1                   |       |
    +----------+--------------+------+-----+---------------------+-------+
    When vacation/autoreply is activated the "goto" field is added a new adress.
    At first it's: "test@domain.com" and after it's "test@domain.com,test#domain.com@autoreply.domain. com"

    The "autoreply.domain.com" is specified in the configuration.

    The vacation table looks like this:

    Code:
    +---------+--------------+------+-----+---------------------+-------+
    | Field   | Type         | Null | Key | Default             | Extra |
    +---------+--------------+------+-----+---------------------+-------+
    | email   | varchar(255) | NO   | PRI | NULL                |       |
    | subject | varchar(255) | NO   |     | NULL                |       |
    | body    | text         | NO   |     | NULL                |       |
    | cache   | text         | NO   |     | NULL                |       |
    | domain  | varchar(255) | NO   |     | NULL                |       |
    | created | datetime     | NO   |     | 0000-00-00 00:00:00 |       |
    | active  | tinyint(1)   | NO   |     | 1                   |       |
    +---------+--------------+------+-----+---------------------+-------+
    And the information is added/modified like this:

    email: "test@domain.com"
    subject: "autoreply" (or whatever you write)
    body: "On vacation" (or whatever autoreply you want to send)
    cache: this is empty, don't know what it's for.
    domain: "domain.com" the domain name from the email-adress.
    created: "2010-09-10 12:30:21" current date when activated.
    active: "1" 1 if active, 0 if not.

    I'm no expert but that doesn't look so hard to make a simple plugin that modifies those database entries with two simple text fields and maybe a checkbox for active/not-active..

    Someone who's feeling they can manage the task?
    It would seriously be frigign awesome if it would be done and I would be forever grateful!

    Thanks,
    -Patric

  3. #3
    k1piee is offline Roundcube Newcomer
    Join Date
    Jul 2009
    Posts
    8
    Downloads
    3
    Uploads
    0

    Default

    Bump!

    I asked over at Postfixadmin forums and they told me that I should use XMLRPC instead of modifying the actual database itself. Apparently it's easier to use XMLRPC too, though I have seriously No programming skills when it comes to PHP and XMLRPC, the only skills I have is some "hello world" apps written in Java 5 years ago so..

    Anyone who wants to help out?

    thanks,
    -Patric

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts