I need to send the values of a form that has been submitted to another function on my site in the form of an array. The array is not being populated with the values from checkboxes, but other kinds of inputs are correctly input into the array. The values are being stored correctly in the form entries.
Below are the key parts of the function.
add_action("gform_post_submission_50", "SF_Account_Upsert50", 10, 2);
function SF_Account_Upsert50($entry, $form){
global $wpdb;
$newperson = array();
if (!empty ($entry[30])) {
$newperson['WP_Login__c'] = strtolower($entry[30]); //this is stored correctly
}
if (!empty ($entry[32])){ //is a checkbox ... fails
$newperson['Grade_Level__c'] = $entry[32];
}
//outside the check
$newperson['Grade_Level__c'] = $entry[32]; // inserts empty value
}