Thanks for responding with such care.
I’ll use Code Snippets, that sounds like a great tool.
Assuming I do this, where would I actually call the function cnl_alter_add_entry_object
and what would I need to set up ahead of time to have the right data available?
Although I can sort of hack around PHP code, I don’t understand what filters do. And I’m used to thinking about a function as something one defines in one place, then calls from one or more other places in the interface.
So right now I think I need to add some code to the manage.php file that would successfully call the cnl_alter_add_entry_object function that you just wrote up in the earlier comment. Is that right?
If so, what sort of array of data would I need to set up before the call, and how would the function be called?
Here is the testing code I added to manage.php starting at line 25:
// ——————————————————–
// CODE ADDED BY ERIC BOBROW
// ACCESS USER INFO FROM DIGITAL ACCESS PASS (DAP) DATABASE
include_once “/dap/dap-config.php”;
$user = null;
if( Dap_Session::isLoggedIn() ) {
$session = Dap_Session::getSession();
$user = $session->getUser();
$email = $user->getEmail();
$firstName = $user->getFirst_name();
$lastName = $user->getLast_name();
$userName = $user->getUser_name();
}
echo ‘<p id=”test-mod”>’;
echo $firstName;
echo ‘ – Welcome to the ArchiCAD User Directory!</p>’;
// ACCESS USER INFO FROM INFUSIONSOFT API
include_once “isdk.php”;
$myApp = new iSDK;
# $email = ‘eric@bobrow.com’;
if ($myApp->cfgCon(“demo”)) {
echo ‘<p>Infusionsoft connection successful.</p>’;
$returnFields = array(‘Id’, ‘FirstName’, ‘LastName’, ‘City’, ‘State’, ‘Country’);
$data = $myApp->findByEmail($email, $returnFields);
echo ‘<p>Email address: ‘ , $email , ‘<br />’;
echo ‘First Name: ‘ , $data[“0”][“FirstName”] , ‘<br />’;
echo ‘Last Name: ‘ , $data[“0”][“LastName”] , ‘<br />’;
echo ‘City: ‘ , $data[“0”][“City”] , ‘<br />’;
echo ‘State: ‘ , $data[“0”][“State”] , ‘<br />’;
echo ‘Country: ‘ , $data[“0”][“Country”] , ‘</p>’;
} else {
echo ‘<p>Infusionsoft connection error.</p>’;
}
// END OF ADDED CODE
// ——————————————————–
Right now I haven’t written up the instructions, I’ve just gotten the connections to DAP and Infusionsoft working and know how to echo the returned data at the top of the Connections page.
Yes, the email address on file for my license of your plugin bundle is the one that you can use to send me things. I’m very interested in working with you to get my site optimized, and will be very happy to give you constructive feedback about your interface and features – I have a lot of experience with user interface design.
Eric
