tags:

views:

62

answers:

1

I am using the following code to fetch all mails since 1 day less -

$yesterday = date("Y-m-d", strtotime ("-1 days"));
$searchQuery = 'SINCE "'.$yesterday.'"';

if($this->open($folder)) {
    $imap_search = imap_search($this->_imap, $searchQuery);
}

This works fine on my dev windows machine but when i put it on the test production server it doesn't work. I have even tried ALL as the search parameter but it does not seem to fetch anything. The connection to the mail account (the $this->_imap object) seems to be fine.

Any ideas?

A: 

Since noone else answered, I will put it as a wiki for whoever comes in after me looking for the same issue. The problem I faced was with the php version used on the server (5.2.1). Seems like it has a bug which causes it to segfault. Upgrading the php version fixed the issue for me.

pinaki
accepted my own answer ;)..
pinaki