diff options
author | Ivan Kohler <ivan@freeside.biz> | 2017-12-01 18:31:06 -0800 |
---|---|---|
committer | Ivan Kohler <ivan@freeside.biz> | 2017-12-01 18:31:06 -0800 |
commit | 48e20d8f1d1b7bccbe0f1a37786cb2c42074a5fc (patch) | |
tree | c6b2367ec2c3483495ad1c9a5737eb492f926d82 /fs_selfservice/wordpress/elements/card.php | |
parent | 467e43fa07b998b5bae0d69f22a17955fe25ddd5 (diff) |
add card processing to example self-service, RT#75279
Diffstat (limited to 'fs_selfservice/wordpress/elements/card.php')
-rw-r--r-- | fs_selfservice/wordpress/elements/card.php | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/fs_selfservice/wordpress/elements/card.php b/fs_selfservice/wordpress/elements/card.php new file mode 100644 index 000000000..eb29aef6c --- /dev/null +++ b/fs_selfservice/wordpress/elements/card.php @@ -0,0 +1,53 @@ +<TR> + <TD ALIGN="right">Card number</TD> + <TD COLSPAN=6> + <TABLE> + <TR> + <TD> + <INPUT TYPE="text" NAME="payinfo" SIZE=20 MAXLENGTH=19 VALUE="<?php echo $payinfo ?>"> </TD> + <TD>Exp.</TD> + <TD> + <SELECT NAME="month"> + <?php $months = array( '01', '02', '03' ,'04', '05', '06', '07', '08', '09', '10', '11', '12' ); + foreach ( $months AS $m ) { + ?> + <OPTION <?php if ($m == $month) { echo 'SELECTED'; } ?>><?php echo $m; ?> + <?php } ?> + </SELECT> + </TD> + <TD> / </TD> + <TD> + <SELECT NAME="year"> + <?php $years = array( '2015', '2016', '2017', '2018', '2019', '2020', '2021', '2022', '2023' ); + foreach ( $years as $y ) { + ?> + <OPTION <?php if ($y == $year ) { echo 'SELECTED'; } ?>><?php echo $y; ?> + <?php } ?> + </SELECT> + </TD> + </TR> + </TABLE> + </TD> +</TR> +<?php if ( $withcvv ) { ?> + <TR> + <TD ALIGN="right">CVV2 (<A HREF="javascript:myopen('cvv2.html','cvv2','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,width=480,height=288')">help</A>)</TD> + <TD><INPUT TYPE="text" NAME="paycvv" VALUE="" SIZE=4 MAXLENGTH=4></TD> + </TR> +<?php } ?> +<TR> + <TD ALIGN="right">Exact name on card</TD> + <TD COLSPAN=6><INPUT TYPE="text" SIZE=32 MAXLENGTH=80 NAME="payname" VALUE="<?php echo $payname; ?>"></TD> +</TR> + +<?php $lf = $freeside->mason_comp(array( + 'session_id' => $_COOKIE['freeside_session_id'], + 'comp' => '/elements/location.html', + 'args' => [ + 'no_asterisks' , 1, + #'address1_label' , 'Card billing address', + 'address1_label' , 'Card billing address', + ], + )); + echo $lf['output']; +?> |