function entityconnect_child_form_cancel in Entity connect 7
Same name and namespace in other branches
- 7.2 includes/entityconnect.form.inc \entityconnect_child_form_cancel()
Sets the redirect to a admin/entityconnect/redirect page.
1 string reference to 'entityconnect_child_form_cancel'
- entityconnect_child_form_alter in includes/
entityconnect.form.inc - Alters child create form.
File
- includes/
entityconnect.form.inc, line 504 - Handles all form alters and submit functions for entityconnect.
Code
function entityconnect_child_form_cancel(&$form, &$form_state) {
$cache_id = $form_state['clicked_button']['#parent_build_cache_id'];
if ($cache_id && ($cache = entityconnect_cache_get($cache_id))) {
$form_state['redirect'] = "admin/entityconnect/return/{$cache_id}";
}
}