Re: Wrong parameter count for imap_open()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Adam Williams wrote:
> I'm running PHP 5.2.4 and getting the error:
> 
> *Warning*: Wrong parameter count for imap_open() in
> */var/www/sites/intra-test/contract/login.php* on line *9
> 
> *My code is:
> 
> $mbox =
> imap_open("\"{mail.mdah.state.ms.us/imap/novalidate-cert:143}INBOX\",
> \"".$_POST["username"]."\", \"".$_POST["password"]."\"");   // line 9

>From the documentation, it looks to me like you are makings things much more complicated then they
need to be.

imap_open('{mail.mdah.state.ms.us/imap/novalidate-cert:143}INBOX',
          $_POST["username"],
          $_POST["password"]);

>From what the documentation shows, you do not need to have quotes around the username/password fields.

Enjoy.

> 
> but when I echo it out, it looks fine:
> 
> echo "\"{mail.mdah.state.ms.us/imap/novalidate-cert:143}INBOX\",
> \"".$_POST["username"]."\", \"".$_POST["password"]."\"";
> 
> prints:
> 
> "{mail.mdah.state.ms.us/imap/novalidate-cert:143}INBOX", "awilliam",
> "xxxxxxx"
> 
> 
> any ideas?
> *
> *
> 

-- 
Jim Lucas

   "Some men are born to greatness, some achieve greatness,
       and some have greatness thrust upon them."

Twelfth Night, Act II, Scene V
    by William Shakespeare

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux