Hi,
I've looked all over the forums and if I've missed how to do this, I apologize.
This is for v.1.3 (not v4).
I've taken a look here (http://www.chronoengine.com/tutorials/chronoforms-plugins/437-paid-registration-using-paypal-plugin.html) at this tutorial and although the outcome is exactly what I desire, the process is lacking for our situation. Instead of having a form to fill out payment info, we'd like to follow this path....
1. Direct our members to fill out the registration form info (I assume the Joomla Registration addon here)
2. Then direct to Paypal with payment either from a selection of "buy now" buttons or a dropdown menu (preferably the buttons - I assume the Redirect plugin here)
3. When the member returns to our site, maybe somehow integrate this code from the tutorial to check whether to see if all went well (specifically the Paypal check and delete customer)...
Can someone please help me put this together and/or point me to a link that has this laid out already? Thank you!
I've looked all over the forums and if I've missed how to do this, I apologize.
This is for v.1.3 (not v4).
I've taken a look here (http://www.chronoengine.com/tutorials/chronoforms-plugins/437-paid-registration-using-paypal-plugin.html) at this tutorial and although the outcome is exactly what I desire, the process is lacking for our situation. Instead of having a form to fill out payment info, we'd like to follow this path....
1. Direct our members to fill out the registration form info (I assume the Joomla Registration addon here)
2. Then direct to Paypal with payment either from a selection of "buy now" buttons or a dropdown menu (preferably the buttons - I assume the Redirect plugin here)
3. When the member returns to our site, maybe somehow integrate this code from the tutorial to check whether to see if all went well (specifically the Paypal check and delete customer)...
<?php
$MyPlugins =& CFPlugins::getInstance($MyForm->formrow->id);
if(!$MyPlugins->cf_joomla_registration['errors']){
$MyPlugins->runPlugin('after_email', array('ONSUBMIT', 'ONLOADONSUBMIT'), 'cf_paypal_api');
if($MyPlugins->cf_paypal_api['payment_status'] == 'SUCCESS'){
echo "Thank you for registering at Mysite.com. You will be recieving a confirmation email shortly";
$MyFormEmails =& CFEMails::getInstance($MyForm->formrow->id);
$MyFormEmails->setEmailData(1, 'enabled', '1');
$MyFormEmails->sendEmails($MyForm, $MyFormEmails->emails);
}else{
$regUser = new JUser($MyPlugins->cf_joomla_registration['user']->id);
$regUser->delete();
$MyForm->addErrorMsg( 'An error occured : '.$MyPlugins->cf_paypal_api['error_message'] );
$MyForm->haltFunction["autogenerated_after_email"] = true;
}
}else{
$MyForm->addErrorMsg($MyPlugins->cf_joomla_registration['errors']);
$MyForm->haltFunction["autogenerated_after_email"] = true;
}
?>
Can someone please help me put this together and/or point me to a link that has this laid out already? Thank you!