简体   繁体   English

.ERROR:8-CURL错误:无法解析主机

[英].ERROR: 8 - CURL error: Could not resolve host

I am having this error. 我有这个错误。 Why am getting it any clue? 为什么有任何线索?

This is the complete error am having. 这是一个完整的错误。

ERROR: 8 - CURL error: Could not resolve host: yahoo.com.infusionsoft.com; Host not found

This is my other php file, conn.cfg.php file. 这是我的另一个php文件,conn.cfg.php文件。

<?php

 $connInfo =array('connectionName:applicationName:i:e6256f1d838a342155f51d800945c777:This                is the connection for applicationName.infusionsoft.com');

 ?>

This is my email.php file code. 这是我的email.php文件代码。

 <?php
 echo "Hello World! <br/>";
 include_once ('iSDK/src/isdk.php');
 $myApp = new iSDK();
 if ($myApp->cfgCon("testemail"))
{
echo "Connected...";
}
else
{
echo "Not Connected...";
}
$result = $myApp->sendEmail('conList','fromAddress','kamran_asadi15@yahoo.com',  'ccAddresses', 'bccAddresses', 'contentType', 'subject', 'htmlBody', 'txtBody');
print_r($result);
?>

because yahoo.com.infusionsoft.com is not a valid URL 因为yahoo.com.infusionsoft.com不是有效的网址


Based on your edited question and your posted code it is clear you are using this library: https://github.com/infusionsoft/PHP-iSDK 根据您已编辑的问题和已发布的代码,您显然正在使用此库: https : //github.com/infusionsoft/PHP-iSDK

Chances are you are simply not using the API correctly though I have no experience of that API 尽管我没有使用该API的经验,但您可能根本没有正确使用该API

You are missing the applicationName parameter which is the name of your Infusionsoft application. 您缺少applicationName参数,它是Infusionsoft应用程序的名称。 Here is how it should look like: 它看起来应该像这样:

<?php
$connInfo =array('my_connection:my_application_name:i:e6256f1d838a342155f51d800945c777:This                is the connection for applicationName.infusionsoft.com');
?>

And then you can connect to the service using the connection name like so: 然后,您可以使用连接名称连接到服务,如下所示:

$myApp->cfgCon("my_connection"));

Application name is the name with witch you sign in like : 应用程序名称是您登录时带有的女巫的名称,例如:

http://my_application_name.infusionsoft.com 

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM