<? if($_GET['home'] == "add") {
if  (empty($_POST['nome']) ||
     empty($_POST['valor'])) { // campos obrigatorios
echo "<script>window.location='registrar.php';alert('Preencha todos os campos.');</script>";

	
} else {
	
$fp = fopen("../../../dados/donatario.txt","a");
fwrite($fp,"

<div class=\"news\">
{$_POST['nome']}            <!--NOME-->      <span class=\"date\">
{$_POST['valor']} BRL       <!-- valor -->   </span>
</div>	
										
	
	
	
	
										


\n");
fclose($fp);

echo "<script>window.location='../../../dados/numero.php';alert('donatario registrado com sucesso');</script>";

}
} else {
?>
<HTML>
<HEAD>
<TITLE>::JPADEVS 22999518600 SUPORTE ESPECIALIZADO::</TITLE>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<link href="../styles.css" rel="stylesheet" type="text/css">
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);
//-->

</SCRIPT>
<style type="text/css">
<!--
.style5 {font-size: 12px}
.style11 {font-size: 10px}
-->
</style>
</HEAD>
<Script>
function FadeIn(objname){
var objholder=document.getElementById(objname)
objholder.filters[0].apply()
objholder.style.background="#B9EEFF"
objholder.filters[0].play()
}
function FadeOut(objname){
var objholder=document.getElementById(objname)
objholder.filters[0].apply()
objholder.style.background="#FFFFFF"
objholder.filters[0].play()
}
</Script>
<STYLE type="text/css">
<!-- table, body  {
	font-size: 10px;
	margin-left: 0px;
	margin-top: 0px;
	color: #FFF;
}
input, select { font-family: Arial Narrow; font-size: 10x; font-weight: bold }
.style8 {font-family: Arial, Helvetica, sans-serif}
.style10 {
	color: #FFFFFF
}
</style>
<META content="MSHTML 6.00.2900.2963" name=GENERATOR>

<DIV align=left>
<body>
<TABLE height=101 cellSpacing=0 cellPadding=0 width="21%" border=0>

  <TBODY>
  <TR>
    <TD align=left width="96%" height=101><table width="100%" border="0" align="center">        
      <form name="add_home" method="post" action="?home=add" >

        <tr>
          <td width="21%" height="22" align="right"><span class="style8 style10 style11">NOME</span></td>
          <td width="79%" valign="top"><a href="#" onClick="window.open('http://pt-br.tinypic.com/', 'Pagina', 'STATUS=NO, TOOLBAR=NO, LOCATION=NO, DIRECTORIES=NO, RESISABLE=NO, SCROLLBARS=YES, TOP=160, LEFT=230, WIDTH=530, HEIGHT=300');"><span class="style8 style10 style11"><strong>
          </strong></span></a>
            <input name="nome" type=text id="a" style="Font:Normal 10px Verdana; "
		onFocus="JavaScript:FadeIn('i5')" onBlur="JavaScript:FadeOut('i5')" size="20" maxlength="10"></td>
        
        
        
          
          </tr>
        <tr>
          <td height="22" align="right" valign="top"><span class="style8 style10 style11">VALOR</span></td>
          <td>
            <input name="valor" id="site" type="number" style="Font:Normal 10px Verdana; "
			  onFocus="JavaScript:FadeIn('i2')" onBlur="JavaScript:FadeOut('i2')" size="20" maxlength="10" />
          </td>
          
          
          
        
          
        </tr>
        <tr>
          <td height="22" align="right" valign="top">&nbsp;</td>
          <td>&nbsp;</td>
        </tr>

        <tr>
          <td height="22" align="right">&nbsp;</td>
          <td><input name="Enviar" type="image" src="https://jhernandez.neocities.org/cenfor/boton-enviar.png"  value="Enviar pedido" width="77" height="39" /></td>
        </tr></form> 
      </table>
      <p>&nbsp;</p>
</body>
</HTML>



<? } ?>

