Hey there,
Just wana do something like this, but i want to know which file i have to write the code :-
add_filter('gform_pre_submission_filter_1', 'conditional_message');
function conditional_message($form){
$link = 'http://test.com/test/app?&z=#CURRENCYCODE#p=#PRICE#&bs=Yes&u=#USER#&r=SPP';
$currency = rgpost('input_7');
$price = rgpost('input_8');
$user = rgpost('input_9');
if($currency == 'AU')
$ccode = 'askdfhksahdfk';
if($currency == 'US')
$ccode = 'gsdlllllsaaa';
$link = str_replace("#CURRENCYCODE#",$ccode,$link);
$link = str_replace("#PRICE#",$price,$link);
$link = str_replace("#USER#", $user,$link);
// my modified form for autoResponder
$form['autoResponder']['message'] .= "$link";
// return modified form
return $form;
}
Posted 12 years ago on Tuesday November 13, 2012 |
Permalink