Пример #1
0
if ($existe) {
    echo "<div align='center'";
    echo "<img src=" . "../../imgs/topo2/topo_formulario.png" . " alt=" . "Instituto Federal Baiano" . " />";
    echo "<h2>Requerimento de Inscri&ccedil;&atilde;o</h2>";
    echo "<table border='0'>";
    echo "\t<tr>";
    echo "\t\t<td><div align='center'>Problemas ao preencher o requerimento de inscri&ccedil;&atilde;o. O CPF informado (<b>" . $cpf . "</b>) encontra-se associado a outro candidato.<br/>Caso ocorra algum problema, favor entrar em contato (P&aacute;gina Inicial / Contato).</div></td>";
    echo "\t</tr>";
    echo "\t<tr>";
    echo "\t\t<td><br /><div align='center'><a href=" . "javascript:window.history.go(-1)" . ">Voltar</a>" . " - " . "<a href=" . "../../index.php" . ">P&aacute;gina Inicial</a></div></td>";
    echo "\t</tr>";
    echo "</table>";
    echo "</div>";
} else {
    $banco->startTransaction();
    $id_inscrito = $inscrito->Inserir($conexao);
    if ($id_inscrito > -1) {
        $banco->commitTransaction();
        ?>

	<form id="frmo" name="frm" action="mostrar.php" method="post">
		<input type="hidden" name="cpf" value="<?php 
        echo $cpf;
        ?>
" />
		<input type="hidden" name="pwd" value="<?php 
        echo $senha;
        ?>
" />
		<input type="hidden" name="mensagem" value="0" />
	</form>