All pastes #265201 Raw Edit

Mine

public php v1 · immutable
·published 2006-12-03 02:42 UTC
rendered paste body
 ########### FORMULARIO DA PAGINA (OUTRA) ##############<div id="upload_file" style="position:absolute; visibility:show; left:9px; top:105px; z-index:0"><form name="upload_file" action="cria.php" method="post">   <table class="forumline">     <tr>       <td>Arquivo:</td>     </tr>     <tr>       <td><input name="usufile" type="file"></td>     </tr>     <tr>       <td><input type="submit" value="Upload"></td>     </tr>     <tr>       <td><a href="javascript:history.go(-1);">Voltar</a></td>     </tr>   </table></form></div>     ########### UPLOAD ##############if(isset($_POST['usufile'])){$filex=$_POST['usufile'];$dirx=$_SESSION['dir'];$filexname = $_FILE["usufile"]["name"];  if(file_exists("/" . $dirx . "/" . $filexname)){   print ("arquivo ja existe no servidor...<br>\n");   exit;  }  $store = "/" . $dirx . "/" . $filexname;if(is_uploaded_file($filexname)){   echo "sim";} else {   echo "nao";} if(!move_uploaded_file($_FILE["usufile"]["tmp_name"],$store)){       echo "O arquivo não foi carregado";  }  //PS: aqui vc pode colocar um  //header("Location: ./?p=pub&ext=php");  //fica mais bonito e mais conforme aos padroes  echo "<meta http-equiv=\"refresh\" content=\"0;URL=./?p=pub&ext=php\">";}