<?php /** * @file * Example for Caixa Economica Bank. */ /** * Include the main boleto class file. */ include_once '../../Boleto.class.php'; $myArguments = array('bank_code' => '748', 'bank_code_cd' => 'X', 'agencia' => 1234, 'agencia_dv' => '2', 'conta' => 12345, 'conta_dv' => 3, 'valor_boleto' => '2952.95', 'numero_documento' => '27.030195.10', 'endereco' => 'street name and number', 'cidade_uf' => 'city and state', 'cedente' => 'ABC Company Ltd', 'sacado' => 'John Doe', 'carteira' => 'A', 'carteira_nosso_numero' => '3-1-18-2', 'nosso_numero' => '13871', 'cpf_cnpj' => '000.000.000-00', 'endereco1' => 'street name and number', 'endereco2' => 'city and state', 'demonstrativo1' => 'Your text here', 'demonstrativo2' => 'Your text here', 'demonstrativo3' => 'Your text here', 'instrucoes1' => 'Your text here', 'instrucoes2' => 'Your text here', 'instrucoes3' => 'Your text here', 'instrucoes4' => 'Your text here'); // Instantiate an object and send the array of arguments through. $myBoleto = Boleto::load_boleto($myArguments); // You probably wont need to set this in a real life production enviroment $myBoleto->settingsPropertySetter(array('file_location' => '../..')); // You can change stuff around like this: // $myBoleto->settings['bank_logo'] = 'path-to-logo/logo.jpg'; // echo '<pre>'; // print_r($myBoleto); // If you wanna print out the html then call $myBoleto->output(); // Use $myBoleto->output(FALSE); to only populate the output property without // rendering the html