token_actions_goto_action_form($context)
contributions/token/token_actions.module, line 186
Implementation of a configurable Drupal action. Redirect user to a URL.
<?php
function token_actions_goto_action_form($context) {
$form['url'] = array(
'#type' => 'textfield',
'#title' => t('URL'),
'#description' => t('The URL to which the user should be redirected. This can be an internal URL like node/1234 or an external URL like http://drupal.org.'),
'#default_value' => isset($context['url']) ? $context['url'] : '',
'#required' => TRUE,
);
$form['help'] = array(
'#type' => 'fieldset',
'#collapsible' => TRUE,
'#collapsed' => TRUE,
'#title' => t('Placeholder tokens'),
'#description' => t("The following placeholder tokens can be used in the URL path. Some tokens may not be available, depending on the context in which the action is triggered."),
);
$form['help']['tokens'] = array(
'#value' => theme('token_help', 'all'),
);
return $form;
}
?>