I have come accross a very nice script that displays your message count on your email inbox in a web page.
However, the code is set up for IMAP and I use SMTP on my server. Does anyone know how/what I need to change in the script to have it work for SMTP?
Thanks to anyone for advice/help!Code:<?php $server = "mail.mydomain.com"; $user = "XXXXXX"; $password = "YYYYYY"; $host = "{".$server.":143"."}"."INBOX"; $msgstream = imap_open($host, $user, $password); $check = imap_mailboxmsginfo($msgstream); $count = $check->Nmsgs; imap_close($msgstream); // generate display image $width = (strlen($count)*8)+8; $im = @imagecreate($width, 18); $background_color = imagecolorallocate($im,255,255,255); $text_color = imagecolorallocate($im,0,0,0); imagestring($im,4,4,2,$count,$text_color); imagepng($im); imagedestroy($im); ?>
NEVERMIND!! LOL I got it all figured out!



Reply With Quote
Bookmarks