This week I’ve been tackling a project that has been in the back of my mind for a few months now. I was able to leverage the Constant Contact API to integrate Constant Contact user records with VirtueMart/Joomla user profiles. Now when a user is viewed from within the VirtueMart user manager you will also be able to see/edit their related constant contact record and list subscriptions.
New contacts can be created at the same time as Joomla users and it will auto fill information into the constant contact record based on the VirtueMart information. If an existing user profile that does not have a constant contact record is viewed, then when the profile is saved a new constant contact record will be created for that user. I’ll eventually be making more use of the API to allow users to select from various newsletters when registering so that they will be able to have more targeted communications.
The only issue I ran into was when I uploaded the changes to the live web server with PHP 5.2.11. It seems that on my local server with PHP 5.2.9 everything worked well but the comments in the constant contact class file were causing parse errors. I was able to get around the errors by deleting some of the comments.