Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if( empty($_COOKIE['ic_user_name']) )
- {
- $user = array('user[username]'=> $username,
- 'user[email]' => $email,
- 'user[fname]' => $first_name,
- 'user[lname]' => $last_name,
- 'user[password]' => $password,
- 'user[check_password]' => $check_password
- );
- //Create The User
- $user_log = user::create_user((string)$site_api,$user);
- $output = json_decode($user_log,true);
- if($output['ERROR'] == 0)
- $user_id = $output['user'];
- else
- return $user_log;
- }
- else
- {
- $user_id = $_COOKIE['ic_user_api_key'];
- }
- $card = array('card[ccn]' => $cc_name,
- 'card[ccmo]' => $cc_month,
- 'card[ccyr]' => $cc_year,
- 'card[cvv]' => $cc_vv);
- $transaction = payment::start_payment($user_id,$site_api,$plan,$card);
- $trans_op = json_decode($transaction,true);
- if($output['ERROR']==0)
- $subscription_log = subscription::add_user_subscription($user_id,$plan);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement