<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet href="http://bugs.horde.org/themes/feed-rss.xsl" type="text/xsl"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
 <channel>
  <title>Creating a new folder for spam doesn't work</title>
  <pubDate>Fri, 04 Jul 2008 22:56:41 -0400</pubDate>
  <link>http://bugs.horde.org/ticket/6640</link>
  <atom:link rel="self" type="application/rss+xml" title="Creating a new folder for spam doesn't work" href="http://bugs.horde.org/ticket/6640/rss" />
  <description>Creating a new folder for spam doesn't work</description>

  
  
  <item>
   <title>Creating a new folder for spam does not work. If I select th</title>
   <description>Creating a new folder for spam does not work. If I select the option for creating a new folder in ingo/spam.php, I get the window asking for the name of the spam folder OK, the script gets activated - with an empty string as the argument to fileinto, and with no new folder created on the imap server. Tracing the error in ingo/spam.php, I found something weird in the if-elsif-construction in lines 81-122. Apparently, the new spam folder gets created and set as the spam folder only in case the test $form-&gt;validate($vars) in line 82 fails. But if the script is handling the form request created by the new_folder.js javascript, the test succeeds, and $spam-&gt;setSpamFolder($vars-&gt;get('folder')) (line 83) sets the spam folder to the value of 'folder' - i.e., an empty string.

Apparently, the validate() method should return false if all required variables aren't set. But it appears to be ok for the method that the variables are (implicitely) empty...</description>
   <pubDate>Wed, 23 Apr 2008 08:25:27 -0400</pubDate>
   <link>http://bugs.horde.org/ticket/6640#t44816</link>
  </item>
  <item>
   <title>Can you try this patch, please?
http://cvs.horde.org/diff.p</title>
   <description>Can you try this patch, please?
http://cvs.horde.org/diff.php?r1=1.14&amp;r2=1.15&amp;f=ingo%2Fspam.php</description>
   <pubDate>Thu, 24 Apr 2008 01:15:06 -0400</pubDate>
   <link>http://bugs.horde.org/ticket/6640#t44865</link>
  </item>
  <item>
   <title>&gt; Can you try this patch, please?
&gt; http://cvs.horde.org/di</title>
   <description>&gt; Can you try this patch, please?
&gt; http://cvs.horde.org/diff.php?r1=1.14&amp;r2=1.15&amp;f=ingo%2Fspam.php

Now I can successfully create a new folder, but it doesn't end up as the spam folder (the script only creates the new folder). Moreover, if I try to select the newly created folder as the spam folder immediately after creating it this way, I get an error such as 'WarningThe folder &quot;maym&quot; already exists' (and the spam folder isn't changed). Same if I try to select the folder again directly after getting the error. If I return to the rules list, go back to spam.php and then select my new folder as the spam folder, it works OK.</description>
   <pubDate>Thu, 24 Apr 2008 03:16:33 -0400</pubDate>
   <link>http://bugs.horde.org/ticket/6640#t44870</link>
  </item>
  <item>
   <title>Okay, another try:
http://cvs.horde.org/diff.php?r1=1.15&amp;r2</title>
   <description>Okay, another try:
http://cvs.horde.org/diff.php?r1=1.15&amp;r2=1.16&amp;f=ingo%2Fspam.php

(I don't have this set up, sorry for the trial-and-error)</description>
   <pubDate>Fri, 25 Apr 2008 00:17:19 -0400</pubDate>
   <link>http://bugs.horde.org/ticket/6640#t44913</link>
  </item>
  <item>
   <title>This one appears to work. Thanks for replying so fast. :)</title>
   <description>This one appears to work. Thanks for replying so fast. :)</description>
   <pubDate>Fri, 25 Apr 2008 05:06:12 -0400</pubDate>
   <link>http://bugs.horde.org/ticket/6640#t44928</link>
  </item>
  <item>
   <title>Thanks for your quick feedback!</title>
   <description>Thanks for your quick feedback!</description>
   <pubDate>Fri, 25 Apr 2008 10:47:44 -0400</pubDate>
   <link>http://bugs.horde.org/ticket/6640#t44936</link>
  </item>
  <item>
   <title>&gt;&gt; Can you try this patch, please?
&gt;&gt; http://cvs.horde.org/</title>
   <description>&gt;&gt; Can you try this patch, please?
&gt;&gt; http://cvs.horde.org/diff.php?r1=1.14&amp;r2=1.15&amp;f=ingo%2Fspam.php
&gt;
&gt; Now I can successfully create a new folder, but it doesn't end up as 
&gt; the spam folder (the script only creates the new folder). Moreover, 
&gt; if I try to select the newly created folder as the spam folder 
&gt; immediately after creating it this way, I get an error such as 
&gt; 'WarningThe folder &quot;maym&quot; already exists' (and the spam folder isn't 
&gt; changed). Same if I try to select the folder again directly after 
&gt; getting the error. If I return to the rules list, go back to spam.php 
&gt; and then select my new folder as the spam folder, it works OK.

I upgraded to -RC4, and now seem to be back in this situation (it no logner works correctly). I tried re-applying the patch that did work; it didn't fit. I also tried to un-apply the older patch in case that had somehow found its way to the -RC4 instead of the newer one, but that didn't work, either.</description>
   <pubDate>Wed, 21 May 2008 06:00:52 -0400</pubDate>
   <link>http://bugs.horde.org/ticket/6640#t45431</link>
  </item>
  <item>
   <title>&gt;&gt;&gt; Can you try this patch, please?
&gt;&gt;&gt; http://cvs.horde.or</title>
   <description>&gt;&gt;&gt; Can you try this patch, please?
&gt;&gt;&gt; http://cvs.horde.org/diff.php?r1=1.14&amp;r2=1.15&amp;f=ingo%2Fspam.php
&gt;&gt;
&gt;&gt; Now I can successfully create a new folder, but it doesn't end up as
&gt;&gt; the spam folder (the script only creates the new folder). Moreover,
&gt;&gt; if I try to select the newly created folder as the spam folder
&gt;&gt; immediately after creating it this way, I get an error such as
&gt;&gt; 'WarningThe folder &quot;maym&quot; already exists' (and the spam folder isn't
&gt;&gt; changed). Same if I try to select the folder again directly after
&gt;&gt; getting the error. If I return to the rules list, go back to spam.php
&gt;&gt; and then select my new folder as the spam folder, it works OK.
&gt;
&gt; I upgraded to -RC4, and now seem to be back in this situation (it no 
&gt; logner works correctly). I tried re-applying the patch that did work; 
&gt; it didn't fit. I also tried to un-apply the older patch in case that 
&gt; had somehow found its way to the -RC4 instead of the newer one, but 
&gt; that didn't work, either.

...moreover, the spam.php in -RC3 that did work with the patch and the spam.php in -RC4 that doesn't work appear to be identical... I'm confused.
</description>
   <pubDate>Wed, 21 May 2008 06:48:21 -0400</pubDate>
   <link>http://bugs.horde.org/ticket/6640#t45434</link>
  </item>
  <item>
   <title>&gt; ...moreover, the spam.php in -RC3 that did work with the p</title>
   <description>&gt; ...moreover, the spam.php in -RC3 that did work with the patch and 
&gt; the spam.php in -RC4 that doesn't work appear to be identical... I'm 
&gt; confused.

...OK, this is even more confusing: what happens with horde rc3 and rc4 /is/ identical, that is: the folder gets created OK; the script gets created ok (if spam filter is clicked to be active - if it isn't, then when I click it to be active, I get the correct script). But in the &quot;Folder to receive spam&quot; field there is still the text &quot;Select target folder&quot;, not the name of the newly created folder. And if I try to select the newly created folder (that's really already selected), Ingo tries to recreate it (and fails). However, the &quot;Script&quot; page shows the correct script and spam folder. Then, if I log out and log in, the &quot;Script&quot; page shows a spam filter script which has as its spam target folder the folder that is set in IMP preferences, that is, the Spam folder setting... and the &quot;Spam&quot; page shows only the text &quot;Select target folder&quot;. There appears to be something wrong with being able to set the spam folder both in IMP preferences and in spam.php... if I set the spam folder to be None in IMP preferences, then it turns to &quot;&quot; in the &quot;current&quot; script after re-login... The new spam folder creation javascript in IMP options appears to work better than the one in spam.php, but it doesn't activate spam filtering or anything... maybe it would be possible to take it away from IMP options and put similar logic into spam.php or something?</description>
   <pubDate>Wed, 21 May 2008 07:23:31 -0400</pubDate>
   <link>http://bugs.horde.org/ticket/6640#t45435</link>
  </item>
  

 </channel>
</rss>
