Commit f7532b0a authored by Alan Garcia's avatar Alan Garcia

Pour #1350

Squirrelmail OK

Roundcube TODO
parent e695678a
......@@ -73,10 +73,9 @@ class m_roundcube {
* @return boolean
*/
function hook_mail_delete_for_real($mail_id, $fullmail) {
// FIXME do something !
// Include Roundcube configuration
// Delete from the roundcube configuration
// Use cleandb.sh filled by roundcube ?
// Use cleandb.sh filled by roundcube ? http://trac.roundcube.net/browser/github/bin/cleandb.sh
printvar($mail_id);
printvar($fullmail);
}
......
......@@ -65,9 +65,29 @@ class m_squirrelmail {
}
} /* Class Squirrelmail */
/* ----------------------------------------------------------------- */
/** Hook called when an email is REALLY deleted (by the cron, not just in the panel)
* @param mail_id integer the ID of the mail in the AlternC database
* @param fullmail string the deleted mail himself in the form of john@domain.tld
* @return boolean
*/
function hook_mail_delete_for_real($mail_id, $fullmail) {
$fullmail2 = str_replace('@','_',$fullmail); // fullname with _ instead of @ (compatibility)
$todel = array (
"$fullmail.abook",
"$fullmail.pref",
"$fullmail2.abook",
"$fullmail2.pref");
foreach ( $todel as $t ) {
if (file_exists($t) ) {
@unlink("/var/lib/squirrelmail/data/$t");
}
}
} // hook_mail_delete_for_real
} /* Class Squirrelmail */
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment