Hi
I have been trying to install and configure imap on my ubuntu server.
I log in as a root through Putty and then do the following:
sudo apt-get install php5-imap
Which now gives me:
Reading package lists… Done
Building dependency tree
Reading state information… Done
php5-imap is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Then a restart on the server:
apache2ctl graceful
After doing this I reload my PHPInfo file at http://www.testuber.co.uk/phpInfo/ and it still doesn’t show imap.
My IMAP script is
<?php
ini_set('display_errors', 1);
error_reporting(E_ALL);
$imapHostname = 'testuber.co.uk';
$imapUsername = 'imaptest@testuber.co.uk';
$imapPassword = '******';
$imapConnection = imap_open('\\{'.$imapHostname.'/imap}INBOX', $imapUsername, $imapPassword) or die('Connection to server failed');
$imapHeaders = imap_headers($imapConnection) or die('Couldn\\'t get emails');
$imapNumEmails = sizeof($imapHeaders);
echo 'You have '.$imapNumEmails.' in your mailbox';
?>
and is located at http://www.testuber.co.uk/emailTest/ and it still shows
Fatal error: Call to undefined function imap_open() in /home/testuser/domains/testuber.co.uk/public_html/emailTest.php on line 9
Any help would be gratefully appreciated.