0

I am trying the code on this page https://help.exacttarget.com/en/technical_library/web_service_guide/technical_articles/managing_subscriber_status_for_one_or_all_lists/

$subscriber = new ExactTarget_Subscriber();    //If you create the new subscriber object . . .
$subscriber->EmailAddress = $email;            //. . . and specify the email address belonging to the subscriber . . .
$subscriber->SubscriberKey = $subscriberkey;   //. . . as well as the subscriber key of the subscriber . . .
$subscriber->Status = "Unsubscribed";          //. . . then you can specify a status of Unsubscribed (that subscriber won't receive messages sent to all lists in your account.

to update a subscriber status, but it does not seem to work. The code seems simple. Did I miss something? Has anyone had experience with this? I'd rather stay away from the Fuel SDK, because so far I'm using the native ET code structure. Thanks!

  • I figured it out, what an ordeal – garek007 Jan 12 '16 at 23:46
  • Could you let us know? Currently having the same issue. – kab8609 Aug 5 '16 at 15:08
  • 1
    See my answer and PM me if you need more help. – garek007 Aug 6 '16 at 23:50
2

I finally figured it out, this is what did it for me. Pretty simple actually and then you just need to pass the client object to the function after you've connected.

function reActivateSubscriber($client){
    $subscriber = new ExactTarget_Subscriber();
    $subscriber->Status = "Active";
    $sublist = new ExactTarget_SubscriberList();
    $sublist->ID = 1298; // specify listID, mine is for the master list.
    $sublist->Action = "update"; // specify what action to apply to subscriber on list (delete, update are other options)
    $sublist->Status = "Active";    
    }

To see it in context, check out my github repository https://github.com/garek007/exacttarget-php-connect

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.