[sork] Vacation and Forwards Configuration

Simon Brereton simon.brereton at dada.net
Mon Apr 26 17:18:50 UTC 2010


Hi

I'm having quite a bit of trouble getting the various sork modules to work..

I don't use accounts, and passwd is working now, but forward and vacation are somewhat more troublesome.

I have a straight forward Forwards question.  My mail DB is called Mail and mail account details are stored in MailAccounts.  As of yesterday, there is a new column called ImpForward.  In the conf.php I have:

$conf[server][params][query_select]	SELECT ImpForward  FROM  MailAccounts WHERE  Username = \U;
$conf[server][params][query_set]		UPDATE MailAccounts SET ImpForward = 1 WHERE Username  = \U;  UPDATE MailAccounts SET ForwardAdd = \T  WHERE  Username  = \U;
$conf[server][params][query_disable]	UPDATE MailAccounts SET ImpForward = 0 WHERE Username = \U; UPDATE MailAccounts SET ForwardAdd = \U;
$conf[server][params][column_target]	
$conf[server][params][column_keeplocal]	

I don't know what to use for the last two and there's nothing in the horde db (which is what I assumed they were referencing).  I don't mind adding these to my MailAccounts Table, but that will alter the next question I have:

The first query seems to work, but Forwards reports forwarding as on when the ImpForward is empty of equal to 0.  I would expect it to report forwarding on when ImpForward is set to 1 - no?

The second and third only work when if I use one statement - so either it updates the ImpForward column with the status, or changes the ForwardAdd column with the status, but now both.  Please can you tell me how I can do this - or if I'm doing something stupid here?  My assumption is that 

Query-select should ask if forwarding is on or off and populate the field with the forward_to address (if any).
Query_set should set forwarding to 1 or Y or true, and set the forwarding address.
Query_disable should set the set the forward to off/0/false and reset the forwarding address (which for a litany of reasons in my system needs to be the email address) even when forwarding is off..

If these assumptions are not correct, please can you guide me to the correct one?


For Vacations, I have a rather larger issue - and I shold probably solve the forwarding question first.  But basically, my MailAccounts table has AutoResp, AutoRespSub and AutoRespTxt fields.  I would like to reference and set those.  Can you tell me which file(s) I  would need to change to do that? 

Thanks

Simon






More information about the sork mailing list