Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- if ( !defined( 'ABSPATH' ) ) exit;
- if ( !class_exists( 'CHN' ) ) :
- class CHN extends Base {
- // URL Path CNH
- protected $url_path = '/v1/path';
- // Array campos
- public $doador = array();
- // Array campos - cartão
- public $dados = array();
- public $credito = array();
- public $cpf;
- public $nome;
- public $data_nascimento;
- public $email;
- public $celular;
- public function __construct() {
- }
- public function generate_json() {
- $json_array = array(
- $this->doador
- );
- return json_encode($json_array);
- }
- public function finish_order() {
- $return = $this->CallAPI("POST", $url_base, $this->generate_json);
- }
- }
- $newDados = new Dados_CHN();
- $newDados->doador = array(
- "cpf" => $cpf,
- "nome" => $nome,
- "data_nascimento" => $data_nascimento,
- "email" => $email,
- "celular" => $celular,
- );
- endif;
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement