Header(array('settings' => 'Settings', 'help' => 'Help'), 'show_thanks_message_config_{n}');
echo $PluginTabsHelper->tabStart('settings');
echo $HtmlHelper->input('action_redirect_user_{n}_target_url_config',
array(
'type' => 'text',
'label' => "Target URL",
'class' => 'big_input',
'smalldesc' => "The target URL to send the user to."
));
echo $PluginTabsHelper->tabEnd();
echo $PluginTabsHelper->tabStart('help');
?>
- Enter a URL here if you want to Redirect the User after the form is submitted and processed.
- To set parameters in the Redirect URL, use the Configure Redirect action before this action and leave the URL here empty.
- This should be the last action in the OnSubmit Event.
tabEnd();
?>
PK W‰?\‘õEò` ` redirect_user.phpnu W+A„¶ 'redirect', 'title' => 'Redirect/Remote Submit');
var $details = array('title' => 'ReDirect User', 'tooltip' => 'Will redirect the user to another url.');
function run($form, $actiondata)
{
$mainframe = JFactory::getApplication();
$params = new JParameter($actiondata->params);
if ( isset($form->data['redirect_url']) && $form->data['redirect_url'] ) {
$redirect_url = $form->data['redirect_url'];
} else {
$redirect_url = $params->get('target_url');
}
if ( !$redirect_url ) {
$form->debug['redirect_user'][] = 'Error: No Redirect URL found';
return false;
}
$form->debug['redirect_user'][] = 'redirect_user_target_url: '.$params->get('target_url');
//$mainframe->enqueuemessage('$form: '.print_r($form, true).'