BigCommerce - Hosted Ecommerce Software by Interspire

Interspire Forum

 
Go Back   Interspire Forum > Interspire Email Marketer Community Forum > Customization and Integration

Reply
 
Thread Tools Display Modes
  #1  
Old 02-12-2009, 08:55 PM
scubby + scubby is offline
Interspire Customer
 
Join Date: Feb 2009
Posts: 3
Default SaveSubscriberCustomerField on check box list (list of booleans)

One of the fields in my database is a list of check boxes. I'm trying to populate the list of check boxes with an array of booleans, one for each element in the check box list. Seems like a fairly logical way to do it...doesn't work though.

My code looks like this (there are 2 check boxes in this field):

$subscriberApi->SaveSubscriberCustomField(
$id, $field["fieldid"], array($checkbox1_checked, $checkbox2_checked));

Is that not how it's done?
Reply With Quote
  #2  
Old 02-16-2009, 03:42 PM
scubby + scubby is offline
Interspire Customer
 
Join Date: Feb 2009
Posts: 3
Default

Ok, I solved this problem after hours of chain-sawing through the IEM database and source code.

The correct usage is like this:

$subscriberApi->SaveSubscriberCustomField($id, $field["fieldid"],
array("apples", "bananas", "oranges"));

You place the names of the options that you want checked in an array of strings.

Also, options have "display names" as well as internal names. Make sure you're referencing an option by it's internal name, not the display name (although they are most likely the same thing).
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump