Ir para conteúdo
Fórum Script Brasil
  • 0

O Server Tá Com Display_errors = Off


carlosmandra

Pergunta

1 resposta a esta questão

Posts Recomendados

  • 0

Pessoal, já consegui aqui. Abaixo está um script de debug pra incluir no site, ele faz um include do arqivo q você apontar:

<? 
//Turn on display_errors 
ini_set('display_errors','1');

// Display ALL errors including notices 
error_reporting (E_ALL);

if(isset($filename)) 
{ 


// Strip off any dot dot slashes 
$filename = preg_replace("/\.\.\//", "", $filename); 
// Strip off any leading slashes 
$filename = preg_replace("/^\//", "", $filename);

} 
?> 

<html> 
<head> 
<title>PHP Debugger!</title> 
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> 
</head> 
<body> 
<form name="debug" method="post" action="<?$PHP_SELF?>"> 
<table width="500" border="0" align="center"> 
<tr> 
<td colspan="2">Enter the name of the file you would like to debug below. This debug script will attempt to include the file, execute it, and display any errors and notices. This filename should be relative to your web site's root directory.</td> 
</tr> 
<tr> 
<td width="121"> <div align="right">Filename:</div> </td> 
<td width="369"> <input name="filename" type="text" id="filename" 
<? 
if(isset($filename)) 
{ 


// Display the filename if defined 
echo "value=\"$filename\"";
} 
?> 
></td> 
</tr> 
<tr> <td>&nbsp; </td> 
<td> <input type="submit" name="Submit" value="Debug!"> </td> 
</tr> 
</table> 
</form> 
<hr> 
<? 
if(isset($filename)) 
{ 

// Display the filename 
echo "<p align=center>Evaluating $filename</p>"; 

// Include the specified file for debugging 
include "$filename";

} 
?> 
<hr> 
</body> 
</html>

Abraço a todos

Link para o comentário
Compartilhar em outros sites

Participe da discussão

Você pode postar agora e se registrar depois. Se você já tem uma conta, acesse agora para postar com sua conta.

Visitante
Responder esta pergunta...

×   Você colou conteúdo com formatação.   Remover formatação

  Apenas 75 emoticons são permitidos.

×   Seu link foi incorporado automaticamente.   Exibir como um link em vez disso

×   Seu conteúdo anterior foi restaurado.   Limpar Editor

×   Você não pode colar imagens diretamente. Carregar ou inserir imagens do URL.



  • Estatísticas dos Fóruns

    • Tópicos
      152,1k
    • Posts
      651,7k
×
×
  • Criar Novo...