
Mushfiqur Rahman - 2011-05-29 09:53:12
Hi,
I am using your pop3 and it's working great. Before telling about my problem I think I need to say something about my objective of using it.
I want to pop mails from various account and also want to parse them so that I can store them properly in my database.
That's why I am using a loop. First of all I make a list of messages which is pop-able and do this in a loop. After creating that list I start to parse them one by one in another loop. All the works I am doing in a single Open and Close connection.
Now I am telling about my problem. When I want to decode a message from gmail I need to create a parameter called $parameters which will be passed to $mime->decode() method. Would you please explain how should I make a $message_file variable for the $parameters argument for gmail and other email account?
I am giving an example:
If I made it in the following way then it failed to parse all messages (one by one)from gmail.
[code]
for($no_of_message_to_decode=1;$no_of_message<=$total_popable_message;$no_of_message_to_decode++)
{
.......
$message_file='pop3://'.UrlEncode($user).':'.UrlEncode($password).'@'.$hostname.':'.$port.'/'.$no_of_message_to_decode.'?tls='.$tls.'&debug='.$debug.'&html_debug='.$html_debug;
.......
}
[/code]
but if I create it in the following way then it can decode all messages from gmail but failed to decode from other account:
[code]
for($no_of_message_to_decode=1;$no_of_message<=$total_popable_message;$no_of_message_to_decode++)
{
.......
$message_file='pop3://'.UrlEncode($user).':'.UrlEncode($password).'@'.$hostname.':'.$port.'/1'.'?tls='.$tls.'&debug='.$debug.'&html_debug='.$html_debug;
.......
}
[/code]
Would you please how can I create this variable in a general form?
Waiting for your response.
Thanks.
Mushfique