Place cancel link on new php page

Discussion in 'Integration' started by rmeder, Oct 11, 2007.

  1. rmeder

    rmeder New Member

    Joined:
    Sep 3, 2007
    Messages:
    3
    I have done a bit of searching and I haven't been able to find answers to the following:

    I have created a stand alone php page that begins the signup process. I have payment history on this page, but I would also like to have the cancel link. How can I pull the cancel link info a php page.

    I would also like to dynamically create the payment system dropdown list, but I can't find it in the tables. Where is this pulled from.

    Thanks for any assistance!

    Regards,

    Rick
  2. alexander

    alexander Administrator Staff Member

    Joined:
    Jan 8, 2003
    Messages:
    6,279
    Here is how cancel link created for cc_core based plugins:
    Code:
    function cc_core_get_cancel_link($plugin, $payment_id){
        global $cc_core, $config, $db;
        $p = $db->get_payment($payment_id);
        $member = $db->get_user($p['member_id']);
        $action='cancel_recurring';
        $v = get_cc_info_hash($member, $action);
        if (!$p['data']['CANCELLED'])
            return "{$config[root_surl]}/plugins/payment/cc_core/cc.php?"
                ."action=$action&payment_id=$payment_id&"
                ."member_id={$p[member_id]}&v=$v";
    }
    

    In regards to paysystems, have a look in /amember/member.php :
    $paysystems = get_paysystems_list();

Share This Page