[imp] Suggestion: Drafts

Jan Schneider jan@horde.org
Tue, 19 Feb 2002 12:17:10 +0100


Zitat von Ahmed <ashihab@alcahest.com>:

> 
> Is it possible to add a preference to IMP to enable drafts to be 
> saved with the unseen status?
> 
> this will enable me to know how many unfinished drafts are in the 
> drafts folder from the Horde summary page.
> 
> I know the change in imp/compose.php is simple, line 912 
> 
> from: $append_flags = '\\Draft \\Seen';
> to  : $append_flags = '\\Draft';
> 
> but the change to add it as preference is beyond my very limited PHP 
> capabilities :-(

That's not so hard to do. Add a preference like:

$_prefs['seen_drafts'] = array(
    'value' => 0,
    'locked' => false,
    'shared' => false,
    'type' => 'checkbox',
    'desc' => _("Save Drafts as seen.")
);

Add 'seen_draft' to one of the preferences groups and add the seen flag in 
compose.php in a conditional: 

if ($prefs->getValue('seen_drafts'))

Jan.

--
http://www.horde.org - The Horde Project
http://www.ammma.de - discover your knowledge
http://www.tip4all.de - Deine private Tippgemeinschaft