foreach ($customInformation as $k) { // Contain arrays of CustomField objects foreach ($v->{$k} as $customfield) { $answer = ''; foreach ((array) $customfield->answers as $li) { // if it's a date, treat it as such if (preg_match('/^20[0-9]{2}\\-/', $li)) { $li = constant_contact_event_date($li); } $answer .= '<li>' . $li . '</li>'; } $val = "<ul class='ul-disc'>{$answer}</ul>"; $customs[$customfield->question] = $val; } } $data = array(__('Registration Information', 'ctct') => array(__('Registration Status', 'ctct') => $v->registrationStatus, __('Registration Date', 'ctct') => constant_contact_event_date($v->registrationDate), __('Guest Count', 'ctct') => get_if_not_empty($v->guestCount, 1), __('Payment Status', 'ctct') => $v->paymentStatus, __('Order Amount', 'ctct') => $v->orderAmount, __('Currency Type', 'ctct') => $v->currencyType, __('Payment Type', 'ctct') => $v->paymentType, __('Summary of Costs', 'ctct') => $costs), __('Personal Information', 'ctct') => array(__('Name', 'ctct') => $v->title, __('Email', 'ctct') => get_if_not_empty($v->email, '', "<a href='mailto:{$v->email}'>{$v->email}</a>"), __('Phone', 'ctct') => $v->personalInformation->phone, __('Cell Phone', 'ctct') => $v->personalInformation->cellPhone, __('Address', 'ctct') => constant_contact_create_location($v->personalInformation)), __('Business Information', 'ctct') => array(__('Company', 'ctct') => $v->businessInformation->company, __('Job Title', 'ctct') => $v->businessInformation->jobTitle, __('Department', 'ctct') => $v->businessInformation->department, __('Phone', 'ctct') => $v->businessInformation->phone, __('Fax', 'ctct') => $v->businessInformation->fax, __('Website', 'ctct') => $v->businessInformation->website, __('Blog', 'ctct') => $v->businessInformation->blog, __('Address', 'ctct') => constant_contact_create_location($v->businessInformation)), __('Custom Information', 'ctct') => $customs); echo constant_contact_generate_table($data); ?> <p class="submit"><a href="<?php echo remove_query_arg(array('registrant', 'refresh')); ?> " class="button-primary"><?php _e('Return to Event', 'ctct'); ?> </a> <a href="<?php echo add_query_arg('refresh', 'registrant'); ?> " class="button-secondary alignright" title="<?php _e('Registrant data is stored for 1 hour. Refresh data now.', 'ctct'); ?>
} ?> <tr <?php echo $alt; ?> > <td><?php echo $reg->title; ?> </td> <td><?php echo_if_not_empty($reg->email, '', "<a href='mailto:{$reg->email}'>{$reg->email}</a>"); ?> </td> <td><?php echo_if_not_empty($reg->registrationDate, __('None', 'ctct'), constant_contact_event_date($reg->registrationDate)); ?> </td> <td><?php echo_if_not_empty($reg->guestCount, 1); ?> </td> <td><?php echo $reg->paymentStatus; ?> </td> <td><a href="<?php echo add_query_arg('registrant', constant_contact_get_id_from_object($reg), remove_query_arg('refresh')); ?> ">View Details</a></td> </tr>
</th><td><?php echo $v->eventType; ?> </td></tr> <tr><th scope="row" id="start" class="manage-column column-name" style=""><?php _e('Start', 'ctct'); ?> </th><td><?php echo !empty($v->startDate) ? constant_contact_event_date($v->startDate) : __('None', 'ctct'); ?> </td></tr> <tr><th scope="row" id="end" class="manage-column column-name" style=""><?php _e('End', 'ctct'); ?> </th><td><?php echo !empty($v->endDate) ? constant_contact_event_date($v->endDate) : __('None', 'ctct'); ?> </td></tr> <tr><th scope="row" id="registrationurl" class="manage-column column-name" style=""><?php _e('Registration URL', 'ctct'); ?> </th><td><?php echo_if_not_empty($v->registrationUrl, '', '<a href="' . $v->registrationUrl . '">' . $v->registrationUrl . '</a>'); ?> </td></tr> <tr class="alt"><th scope="row" id="location" class="manage-column column-name" style=""><?php _e('Location', 'ctct'); ?> </th><td><?php echo constant_contact_create_location($v->eventLocation); ?>
?> " /> </td> <?php if (!isset($_GET['status']) || $_GET['status'] == 'all') { ?> <td class="column-role wrap"> <?php echo ucwords(strtolower(esc_html($v->status))); ?> </td> <?php } ?> <td class="column-role column-startdate wrap"> <?php echo isset($v->startDate) ? constant_contact_event_date($v->startDate) : __('None', 'ctct'); ?> </td> <td class="column-id column-count wrap"> <?php echo_if_not_empty($v->registered, 0); ?> </td> </tr> <?php flush(); } ?> </tbody> </table>