2

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

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

 ?>

This is my email.php file code.

 <?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);
?>
Kamran Asadi
  • 85
  • 2
  • 7

2 Answers2

1

because yahoo.com.infusionsoft.com is not a valid URL


Based on your edited question and your posted code it is clear you are using this library: https://github.com/infusionsoft/PHP-iSDK

Chances are you are simply not using the API correctly though I have no experience of that API

edmondscommerce
  • 2,001
  • 12
  • 21
0

You are missing the applicationName parameter which is the name of your Infusionsoft application. 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 
xmaestro
  • 1,084
  • 2
  • 16
  • 44