IMAP and PHP4 Help
| From: | Brian C. Doyle | Date: | Sun, 18 Jun 2000 15:27:48 +0000 |
| Subject: | IMAP and PHP4 Help | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-2156@lists.php.net to get a copy of this message | ||
Hello all,
I am trying to work with the imap functions of PHP4. I have installed imapd and have it running. I configured PHP --with-imap after "Then copy c-client/c-client.a to /usr/local/lib/libc-client.a or some other directory on your link path and copy c-client/rfc822.h, mail.h and linkage.h to /usr/local/include ...."
I did not get any errors durring the compiling or making of PHP so i copied php.ini-dist to /usr/local/lib/php.ini
I restarted apache and tried the script i got from www.php.net
<?
$mbox = imap_open ("{pop.pussplayhouse.com/pop3:110}", "boots", "beccam72");
echo "<p><h1>Mailboxes</h1>\n";
$folders = imap_listmailbox ($mbox, "{your.imap.host:143}", "*");
if ($folders == false) {
echo "Call failed<br>\n";} else {
while (list ($key, $val) = each ($folders)) {
echo $val."<br>\n";
}
}
echo "<p><h1>Headers in INBOX</h1>\n";
$headers = imap_headers ($mbox);
if ($headers == false) {
echo "Call failed<br>\n";} else {
while (list ($key,$val) = each ($headers)) {
echo $val."<br>\n";
}
}
imap_close($mbox);
?>
and i get
PHP Fatal error: Call to undefined function: imap_open() in /home/httpd/bootsplayground/demo/popmail.php on line 11
Does anyone have a clue as to what i did wrong or how i should have set it up???
Do you i need to recomplie and install Apache??
Thanks in advance