Forums

Specific Thank You Pages Based on Radio Button Selection

pmsquillace 23 Jun, 2009
Hello All:

I am creating a form so that when people register at my site they have to select between two radio buttons. I would like the thank you page to change based on this selection.

I wrote a <php> script that is basically if else but, I am not sure how to integrate this into my form. Should it be on submit in the reg plugin or in the form config itself?

Thanks for any help or advice on this matter,

Paul
pmsquillace 24 Jun, 2009
ok,

in the CODE part of the form I have this php code but it does not seem to be working,

if any php gurus know if I got this right or not or this is a chronoforms thing please let me know,

<?php
if(isset($_POST['radio00'])) header("location $url"); {
$URL="http://emrcontractor.com/index.php?option=com_content&view=article&id=8&Itemid=2"
}else{
$URL="http://emrcontractor.com/index.php?option=com_content&view=article&id=1&Itemid=3"
}
?>

thanks for any help on this,

Paul
Max_admin 24 Jun, 2009
Hi Paul,

your code should be in the onSubmit after email box and:



<?php
if(isset($_POST['radio00'])){
$URL="http://emrcontractor.com/index.php?option=com_content&view=article&id=8&Itemid=2"
}else{
$URL="http://emrcontractor.com/index.php?option=com_content&view=article&id=1&Itemid=3"
}
global $mainframe;
$mainframe->redirect($URL);
?>


Regards
Max
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
This topic is locked and no more replies can be posted.