Icon Systems main dove logo

IconCMO API — Events Setup

Return to IconCMO Home Page

graphic of event calendar integration

The events example shows a PHP-based calendar that displays the "Events" section of IconCMO on your website in list, day, and monthly formats.

Security Set-up

You'll need to set up a web services account for the calendar, giving it read-only access to the "Events" information from IconCMO.

  1. Go to the "Web Service Security" menu, which is found under Web-Services→Setup.
  2. In the upper right, add a user name and password and click "Save". Keep track of them; you'll need to enter them again while configuring the web server.
  3. Find the user name you just added in the list to the right and click on it. In the bottom left, you'll see that their name appears in the "Modify Security For" menu.
  4. In the "List of Functions" menu directly about the "Modify Security For" menu, choose "Web: Events".
  5. Check the "Read" check box and click "Set Security."

Continue by installing the necessary files onto your web server.

Web Server Set-up

System Requirements

You will need a web server with PHP version 5 or later installed. Additionally, the CURL extension needs to be installed. Most web hosting services will be able to provide these—check with your hosting provider if you aren't sure. All web servers are configured differently, so the installation instructions may need slight adaptation if your server is configured uniquely.

Installation of Files

To install:

  1. Download the event demo directory and unzip them in the directory that you want your calendar to appear on your web server.
  2. Take the event.html template from the events directory (that you just unzipped) and move it up one directory. event.html and the events directory should be next to each other.
  3. Next, you need to change the log-in information. Open the event.php file in the events directory. Modify the <Phone>, <Username>, and <Password> sections of the XML at the very top to match the user name set up in IconCMO.
  4. Edit event.html file as you see fit to match the rest of your site.

Maintenance of Events

Ongoing maintenance of events now can be done under the "Event" menu item in IconCMO. (It is found under the Web-Services→Market menu.) Each time an event is added, deleted, or changed on this screen, your web site will immediately reflect the changes.

Congratulations—you've completed your first IconCMO integration!

Common Installation Issues

No calendar appears on Windows web servers

Windows servers often have a difficult time connecting to IconCMO over a secure connection. This can be determined by going to http://your-path-here/events/event.php?month=2&year=2011 in your web browser and examining the result. If it is not XML data, and includes one of the following error messages, you are affected by this problem.

To resolve this problem, you can edit the event.php file slightly. Find the line that contains

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

and insert the following 2 lines after it:

curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);

At a slight decrease in security, this will allow the calendar to function as expected.

If you have any questions about this, please don't hesitate to contact our support.