function uc_store_customer_search_form_submit in Ubercart 6.2
Same name and namespace in other branches
- 5 uc_store/uc_store.module \uc_store_customer_search_form_submit()
Submit handler for uc_store_customer_search_form().
See also
uc_store_customer_search_form()
File
- uc_store/
uc_store.admin.inc, line 276 - Store administration menu items.
Code
function uc_store_customer_search_form_submit($form, &$form_state) {
if (strlen(trim($form_state['values']['first_name'])) == 0) {
$first_name = '0';
}
else {
$first_name = strtolower(trim($form_state['values']['first_name']));
}
if (strlen(trim($form_state['values']['last_name'])) == 0) {
$last_name = '0';
}
else {
$last_name = strtolower(trim($form_state['values']['last_name']));
}
if (strlen(trim($form_state['values']['email'])) == 0) {
$email = '0';
}
else {
$email = strtolower(trim($form_state['values']['email']));
}
drupal_goto('admin/store/customers/search/results/' . $first_name . '/' . $last_name . '/' . $email);
}