跳至內容
選單
此問題已被標幟
1 回覆
3829 瀏覽次數

can anyone help me with this ?

MY CODE

$user = "my_email";
$password = "my_password";
$dbname = "mydbname";
$serverurl= "http://my.server.url:8069";
$connexion = new xmlrpc_client($server_url."/xmlrpc/common");
$connexion->setSSLVerifyPeer(0);
$c_msg = new xmlrpcmsg('login');
$c_msg->addParam(new xmlrpcval($dbname,"string"));
$c_msg->addParam(new xmlrpcval($user,"string")); 
$c_msg->addParam(new xmlrpcval($password,"string")); 
$c_response = $connexion->send($c_msg);
if($c_response->errno !=0){
    die('error: '.$c_response->faultString());
}else{
echo "connexion successful";
//continue my work
}

END CODE



this script return this error

error : une tentative de connexion a échoué car le parti connecté n’a pas répondu convenablement au delé d'une certaine durée ou une connexion établie a échoué car l'hote de connexion n'a pas répondu

頭像
捨棄
最佳答案

The XMLRPC Library that you are using didn't get a response and the request has timed out that means you can't access Odoo in the host machine maybe because access rights problems or Odoo is not running.

Anyways i will provide you with all the php files that you need to make a connection with your database check it here.



Happy to help :) an upvote will be awesome

頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
1
2月 24
1303
1
7月 23
2605
1
2月 23
2428
1
2月 23
2679
1
11月 22
3865