Overview

Namespaces

  • Ctct
    • Auth
    • Components
      • Account
      • Activities
      • Contacts
      • EmailMarketing
      • Tracking
    • Exceptions
    • Services
  • PHP

Classes

  • BounceActivity
  • ClickActivity
  • ForwardActivity
  • OpenActivity
  • OptOutActivity
  • SendActivity
  • TrackingActivity
  • TrackingSummary
  • Overview
  • Namespace
  • Class
  • Tree
 1: <?php
 2: 
 3: namespace Ctct\Components\Tracking;
 4: 
 5: /**
 6:  * Class to wrap a result set of individual activities (ie: OpensActivity, SendActivity)
 7:  *
 8:  * @package     Components
 9:  * @subpackage     CampaignTracking
10:  * @author         Constant Contact
11:  */
12: class TrackingActivity
13: {
14:     public $results = array();
15:     public $next;
16: 
17:     /**
18:      * Constructor to create a TrackingActivity from the results/pagination response from getting a set of activities
19:      * @param array $results - results array from a tracking endpoint
20:      * @param array $pagination - pagination array returned from a tracking endpoint
21:      */
22:     public function __construct(array $results, array $pagination)
23:     {
24:         $this->results = $results;
25: 
26:         if (array_key_exists('next', $pagination)) {
27:             $this->next = substr($pagination['next'], strrpos($pagination['next'], '&next=')+6);
28:         }
29:     }
30: }
31: 
Appconnect PHP SDK API documentation generated by ApiGen 2.8.0