我对 ISPConfig 和 php soap 技术非常陌生。我从http://www.ispconfig.org/page/en/addons/billing-module.html下载了示例脚本
但是当我尝试 add_invoice 时,它告诉 billing_invoice_add 函数我遇到了异常:
//* Create the SOAP client connection
$client = new SoapClient(null, array('location' => $soap_location,
'uri' => $soap_uri,
'trace' => 1,
'exceptions' => 1));
//* Login as remote user
if($session_id = $client->login($username,$password)) {
echo 'Logged successfull. Session ID:'.$session_id.'<br />';
}
//* We will create a invouce for the client with the following ID
$client_id = 4;
//* Optional parameters to override the client address or client settings
$params = array();
//* Add the invoice
$invoice_id = $client->billing_invoice_add($session_id, $client_id, $params); # Here I am getting exception.
echo 'InvoiceID: '.$invoice_id.'<br />';
我能够成功登录。
ispConfig 版本:3.0
请建议任何将发票远程添加到服务器的方法。
我可以在仪表板中添加它。