Thread: Mail Filter
View Single Post
  #7  
Old 8th July 2009, 15:31
Rescue9 Rescue9 is offline
Member
 
Join Date: Jun 2007
Posts: 52
Thanks: 5
Thanked 3 Times in 2 Posts
Default

Till.... makes sense. What happens if we move the " $WhatIsMyTarget = $this->dataRecord["target"] " line into the $content section as such:

Code:
              
		if($this->dataRecord["action"] == 'move') {
		
			$content .= "
 $WhatIsMyTarget = $this->dataRecord["target"]
`test -e ".'$DEFAULT/.'.$WhatIsMyTarget."`
if ( ".'$RETURNCODE'." != 0 )
{
  `maildirmake -f ".$WhatIsMyTarget.' $DEFAULT'."`
  `chmod -R 0700 ".'$DEFAULT/'.$WhatIsMyTarget."`
  `echo INBOX.".$WhatIsMyTarget." >> ".'$DEFAULT'."/courierimapsubscribed`
}
";		
		}
This way the $WhatIsMyTarget variable will be interpreted by maildrop instead of being interpreted by php, right? Also, I'm sure that my ' & " are so screwed up. If you could write the $WhatIsMyTarget variable as the $DEFAULT variable is written then it should be interpreted by maildrop. If not, how do we get the variable interpreted by maildrop instead of being interpreted by php?

I'm going to try loading up the ISP3 server today and changing the .mailfilter file manually to see if this even works.

Last edited by Rescue9; 8th July 2009 at 15:34.
Reply With Quote