sounds like php itself doesnt have it installed..maybe you didnt enable the extensions for php..
for linux server
re-compile PHP with imap, include --with-imap in the arguments. you probaably need the imap libs and include files too for this.
quote from php.net:
'' To get these functions to work, you have to compile PHP with --with-imap[=DIR], where DIR is the c-client install prefix. From our example above, you would use --with-imap=/usr/local/imap-2000b. This location depends on where you created this directory according to the description above. Windows users may include the php_imap.dll DLL in php.ini ''
for windows server
edit the php.ini and remove ';' from the line:
also you might need to copy the php_imap.dll into the /php and /system32 folder to get it to load.