I just compiled my own PHP4 without any errors!

Unfortunately, I can’t figure out how to access my mail using a simple script I created…

Warning: imap_open() [function.imap-open]: Couldn’t open stream {}INBOX in /home/.newley/*****/list.php on line 6

the username I’m using is MXXXXXX@MYDOMAIN.COM

X = the numbers Dreamhost assigns for a mail username. Should I be using ME@MYDOMAIN.COM or ME or MXXXXXX ??

Thanks for your help!


Go with either MXXXXXX (no or



neither worked


How about posting your script with the sensitive info X’d out?


<?php $username = ""; $password = "XXXXXXX"; $mailserver = "{}INBOX"; $mbox = imap_open($mailserver, $username, $password); ?>

i commented the rest out because it can’t connect from here… once this works, i should be okay.


System Linux ralphie 2.4.32-grsec f6b gr217 nfs a32 fuse23 tg opt c8 gr2b-v6.194 #1 SMP Tue Jun 6 15:52:09 PDT 2006 i686
Build Date Nov 22 2006 17:46:09
Configure Command ‘./configure’ ‘–prefix=/home/XXXXXX/php-4.4.4’ ‘–with-config-file-path=/home/XXXXX/php-4.4.4/etc/php4’ ‘–enable-force-cgi-redirect’ ‘–with-xml’ ‘–with-libxml-dir=/home/XXXXXX/php-4.4.4’ ‘–with-freetype-dir=/home/XXXXXXX/php-4.4.4’ ‘–enable-soap’ ‘–with-xsl=/home/XXXXXXX/php-4.4.4’ ‘–with-openssl=/usr’ ‘–with-mhash=/home/XXXXXX/php-4.4.4’ ‘–with-mcrypt=/home/XXXXXX/php-4.4.4’ ‘–with-zlib-dir=/home/XXXXXX/php-4.4.4’ ‘–with-jpeg-dir=/usr’ ‘–with-png-dir=/usr’ ‘–with-gd’ ‘–enable-gd-native-ttf’ ‘–enable-ftp’ ‘–enable-sockets’ ‘–enable-wddx’ ‘–with-iconv=/home/XXXXXX/php-4.4.4’ ‘–enable-sqlite-utf8’ ‘–enable-calendar’ ‘–with-curl=/home/XXXXXXX/php-4.4.4’ ‘–enable-mbstring’ ‘–enable-mbregex’ ‘–with-mysql=/usr’ ‘–with-mysqli’ '–with-imap=/home/XXXXXX/php-4.4.4’
Server API CGI
Virtual Directory Support disabled
Configuration File (php.ini) Path /home/.newley/XXXXXX/php-4.4.4/etc/php4/php.ini
PHP API 20020918
PHP Extension 20020429
Zend Extension 20050606
Debug Build no
Zend Memory Manager enabled
Thread Safety disabled
Registered PHP Streams php, http, ftp, https, ftps, compress.zlib

IMAP c-Client Version 2004


I checked the programmer’s forum and found this tip on imap_open:



funny part was I actually tried it before and it didn’t work. I wonder if it was something to do with the mail server at the time…

I even compiled PHP over again just to make sure I had did it right.


Happy Thanksgiving too!