在帐户中添加多个来源

时间:2018-02-05 10:16:58

标签: php symfony contextio

如何在帐户中添加多个来源..例如我创建帐户test@gmail.com但是我在这个帐户中添加了源test@hotmail.com?,我怎么试试...现在当我收到邮件帐号test@gmail.com和源码test@hotmail.com ..也就是说收到两封电子邮件:this@gmail.com和test@hotmail.com

我尝试使用此代码:

        public function contextAction()
        {
            $contextio = new ContextIO('key', 'secret');
            $s = $contextio->addEmailAccount($this->getUser()->getidContext(),array('server' => 'imap.googlemail.com','username' =>'test@hotmail.com'));
            if($s === false) print_r($contextio->getLastResponse());
            print_r($s->getData());

        }

但我有这个输出:

ContextIOResponse Object
    (
        [headers:protected] => Array
            (
                [request] => 
                [response] => 
            )

        [rawResponseHeaders:protected] => 
        [rawRequestHeaders:protected] => 
        [rawResponse:protected] => {"success":false,"feedback_code":"An email account for this user already exists"}
        [decodedResponse:protected] => Array
            (
                [success] => 
                [feedback_code] => An email account for this user already exists
            )

        [httpCode:protected] => 500
        [contentType:protected] => application/json
        [hasError:protected] => 1
    )

0 个答案:

没有答案