* * @return array */ public function calcular($hr_entrada, $hr_saida) { // Modelo de array que deverá ser retornado $retorno = array('entrada' => null, 'saida' => null, 'trabalhadas' => null); # Capitulo 1 - Laboratorio 1 // Retorno do array return $retorno; } } // Verifica se formulario foi postado if ($_POST) { $obj_Lab1 = new Lab1(); $resultado = $obj_Lab1->calcular($_POST['hr_entrada'], $_POST['hr_saida']); } ?> <html lang="en"> <head> <meta charset="utf-8"> <title>Capítulo 1 - Laboratório 1</title> </head> <body> <form action="" method="post" > <table cellpadding="5" border="1"> <tr><th>Horario Entrada :</th> <td><input type="text" name="hr_entrada" /></td> </tr> <tr><th>Horario Saída :</th> <td><input type="text" name="hr_saida" /></td>