Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5950869
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T17:27:19+00:00 2026-05-22T17:27:19+00:00

This question refers to CampaignMonitor API PHP wrapper, function subscriberAddWithCustomFields(). In the CampaignMonitor back-end

  • 0

This question refers to CampaignMonitor API PHP wrapper, function subscriberAddWithCustomFields().

In the CampaignMonitor back-end I created a custom multi-option (select many) field called ‘Subscribedto’ where the user can select (checkbox) which newsletter he likes to receive: ‘News & Updates’ and/or ‘News from Partners’. Now I would like to update this field using the PHP API wrapper but can’t figure out how to do this.

From my database:
‘News & Updates’ can be either 0 or 1
‘News from Partners’ can be either 0 or 1

The following does not work:

$extras = array('Subscribedto'=>array("News & Updates"=>0,"News from Partners"=>1));
$cm_res = $cm->subscriberAddWithCustomFields($email,$name, $extras);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T17:27:20+00:00Added an answer on May 22, 2026 at 5:27 pm

    Their new v3 API makes this a lot easier. See http://www.campaignmonitor.com/forums/viewtopic.php?id=5166 in their forums for an answer.

    Here’s some sample code from one of my forms:

    $wrap = new CS_REST_Subscribers($list_id, $api_key);
            $result = $wrap->add(array(
                'EmailAddress' => $email,
                'Name' => '',
                'CustomFields' => array(
                    array(
                        'Key' => 'Events',
                        'Value' => 'Event 1'
                    )
                ),
                'Resubscribe' => true
            ));
    
            //echo "Result of POST /api/v3/subscribers/{list id}.{format}\n<br />";
            if($result->was_successful()) {
                $success = true;
                $message = 'Cool!  We\'ll be in touch soon.';
            } else {
                $message = $result->response;
            }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This question refers to both the iOS SDK and JS API for Google Analytics.
This question would probably apply equally as well to other languages with C-like multi-line
This question refers to the question Show/hide fields depending on select value <select id=viewSelector>
Textbox refers to <input type=text> in this question. For each textbox with a given
This question refers to http://www.matthidinger.com/archive/2009/02/08/asp.net-mvc-recursive-treeview-helper.aspx Let's say I have a table that looks like
Is there a way to force garbage collection in VBA/Excel 2000? This question refers
Note: This question refers to a very old version of jQuery.validate() (version 1.5). This
Note 1: This question refers to HTML5 videos only, not Flash videos. Note 2:
This question refers to affiliate marketing, but really is a generic question about intercepting
This question refers to performance, not to file size. I know there are min

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.