Welcome Guest, Not a member yet? Register   Sign In
Form Validation (Twice)
#6

[eluser]PV-Patrick[/eluser]
Hi Michael,
I am trying a different route for dealing with credit card validation/processing. Before, I would authorize the card at the same time as validating the form and stored the authorization status in a session variable. So if the form didn't validate, it wouldn't try and authorize their card on each failed form validation attempt. Thus, I was using an AUTH_ONLY, then PREVIOUS_SALE - 2 function calls for the credit card.

I was trying to bypass this method and use 2 validations and not set session variables so I can then use an AUTH_CONVERT for the CC. I validate the form first as there are two payment methods, 1 for credit card and 1 for paypal, which has two different validation arrays.

I hope that helps, thanks guys!

EDIT: @ macigniter

I guess my way about it is a more nested approach.... Not sure if it matters? Might need to pull it out of each other and basically have it similar to your case.

Code:
if($this->form_validation->run('val1') == FALSE):
    // -- Stop processing
else:
    $bool = TRUE;
endif;

if($bool):
    // -- run val2
endif;


Messages In This Thread
Form Validation (Twice) - by El Forum - 02-06-2009, 04:51 PM
Form Validation (Twice) - by El Forum - 02-06-2009, 05:54 PM
Form Validation (Twice) - by El Forum - 02-06-2009, 05:57 PM
Form Validation (Twice) - by El Forum - 02-06-2009, 06:06 PM
Form Validation (Twice) - by El Forum - 02-06-2009, 06:15 PM
Form Validation (Twice) - by El Forum - 02-06-2009, 06:20 PM
Form Validation (Twice) - by El Forum - 02-06-2009, 07:33 PM
Form Validation (Twice) - by El Forum - 02-07-2009, 02:30 PM
Form Validation (Twice) - by El Forum - 02-12-2009, 12:08 AM
Form Validation (Twice) - by El Forum - 02-13-2009, 08:58 AM



Theme © iAndrew 2016 - Forum software by © MyBB