Ir para conteúdo

POWERED BY:

Arquivado

Este tópico foi arquivado e está fechado para novas respostas.

visitante_php

erro no error

Recommended Posts

minha mensagem de erro esta assim

 

$erro = "( ".date("d/m/Y H:i:s", time())." ) - [ ".mysql_errno()." ] ".$erroMySQL[$erroCodigo_MySQL]. __LINE__ . 'em'.__FILE__."\n\n";
		//echo $erro;
		error_log($erro,3,"erros.log");

e esta saindo assim...

 

[Mon, 10 Nov 2008 16:08:50 -0200] Error 2048: date()

[<a href='function.date'>function.date</a>]: It is not safe to rely on the

system's timezone settings. Please use the date.timezone setting, the TZ

environment variable or the date_default_timezone_set() function. In case

you used any of those methods and you are still getting this warning, you

most likely misspelled the timezone identifier. We selected 'America/Sao_Paulo'

for '-2.0/DST' instead

diferente do que eu tinha formatado...pq?

 

obs.: esta td numa linha so, eu dei quebra d linha para nao ficar aquele post horrivel de se ler....

Compartilhar este post


Link para o post
Compartilhar em outros sites

A sua mensagem formatada existe, só não está exibindo por causa de um erro que ocorre antes que ela possa ser executada para gravar no log, que é a questão da data. Você tem que definir um timezone, como a mensagem de erro indica.

 

[]'s

Compartilhar este post


Link para o post
Compartilhar em outros sites

a funcao esta assim:

 

require 'erro_lib_mysql.php';

function erroMySQL(){
	date_default_timezone_set("America/Sao_Paulo");
	global $erroMySQL;
	$erroCodigo_MySQL = mysql_errno();
	if(array_key_exists($erroCodigo_MySQL, $erroMySQL)){
		$erro = "( ".date("d/m/Y H:i:s", time())." ) - [ ".mysql_errno()." ] ".$erroMySQL[$erroCodigo_MySQL]. __LINE__ . 'em'.__FILE__."\n\n";
		//echo $erro;
		error_log($erro,3,"erros.log");
	}else{
		$erro = "( ".date("d/m/Y H:i:s", time())." ) - [ ".mysql_errno()." ] " .mysql_error(). __LINE__ . ' em '.__FILE__."\n\n";
		error_log($erro,3,"erros.log");
	}
}

Compartilhar este post


Link para o post
Compartilhar em outros sites

continua dando pau.....nao vai continua na mesma...

 

[Mon, 10 Nov 2008 19:12:03 -0200] Error 2048: date() [<a href='function.date'>function.date</a>]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Sao_Paulo' for '-2.0/DST' instead

[Mon, 10 Nov 2008 19:12:03 -0200] Error 8: Undefined variable: class

[Mon, 10 Nov 2008 19:12:03 -0200] Error 8: Undefined offset: 9

[Mon, 10 Nov 2008 19:12:21 -0200] Error 2048: date() [<a href='function.date'>function.date</a>]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Sao_Paulo' for '-2.0/DST' instead

[Mon, 10 Nov 2008 19:12:21 -0200] Error 2048: date() [<a href='function.date'>function.date</a>]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Sao_Paulo' for '-2.0/DST' instead

[Mon, 10 Nov 2008 19:12:21 -0200] Error 8: Undefined index: fk_cat

[Mon, 10 Nov 2008 19:12:21 -0200] Error 8: Undefined index: fk_subcat

[Mon, 10 Nov 2008 19:12:21 -0200] Error 8: Undefined index: palavra_chave

[Mon, 10 Nov 2008 19:12:21 -0200] Error 8: Undefined index: destaque

[Mon, 10 Nov 2008 19:12:21 -0200] Error 8: Undefined index: leitor

[Mon, 10 Nov 2008 19:12:21 -0200] Error 8: Undefined index: secao

[Mon, 10 Nov 2008 19:12:21 -0200] Error 8: Undefined variable: class

[Mon, 10 Nov 2008 19:12:21 -0200] Error 8: Undefined offset: 9

esse eh o erro gerado por um unico insert....

Compartilhar este post


Link para o post
Compartilhar em outros sites

tenho leve impressao de q meus posts estao sendo apagados ...pq kem e pq nao sei....

Por mim e porque post up não é permitido. ;)

 

Algumas variáveis não foram iniciadas, algumas chaves de vetor não existem, enfim, vários erros de sintaxe.

 

[]'s

Compartilhar este post


Link para o post
Compartilhar em outros sites

Algumas variáveis não foram iniciadas, algumas chaves de vetor não existem, enfim, vários erros de sintaxe.

 

[]'s

voce ker dizer

 

require 'erro_lib_mysql.php';

function erroMySQL(){
	date_default_timezone_set("America/Sao_Paulo");
-------------------------------------------------------------------------->>>>>>>	[b]global $erroMySQL;[/b]
	$erroCodigo_MySQL = mysql_errno();
	if(array_key_exists($erroCodigo_MySQL, $erroMySQL)){
		$erro = "( ".date("d/m/Y H:i:s", time())." ) - [ ".mysql_errno()." ] ".$erroMySQL[$erroCodigo_MySQL]. __LINE__ . 'em'.__FILE__."\n\n";
		//echo $erro;
		error_log($erro,3,"erros.log");
	}else{
		$erro = "( ".date("d/m/Y H:i:s", time())." ) - [ ".mysql_errno()." ] " .mysql_error(). __LINE__ . ' em '.__FILE__."\n\n";
		error_log($erro,3,"erros.log");
	}
}

repare nisso

 

----------------------------------------------------------------------------->>>>>>>[b]require 'erro_lib_mysql.php';[/b]

function erroMySQL(){
	date_default_timezone_set("America/Sao_Paulo");
	global $erroMySQL;
	$erroCodigo_MySQL = mysql_errno();
	if(array_key_exists($erroCodigo_MySQL, $erroMySQL)){
		$erro = "( ".date("d/m/Y H:i:s", time())." ) - [ ".mysql_errno()." ] ".$erroMySQL[$erroCodigo_MySQL]. __LINE__ . 'em'.__FILE__."\n\n";
		//echo $erro;
		error_log($erro,3,"erros.log");
	}else{
		$erro = "( ".date("d/m/Y H:i:s", time())." ) - [ ".mysql_errno()." ] " .mysql_error(). __LINE__ . ' em '.__FILE__."\n\n";
		error_log($erro,3,"erros.log");
	}
}

Compartilhar este post


Link para o post
Compartilhar em outros sites

a propria mensagem de erro sugere a correção

 

 

 

We selected 'America/Sao_Paulo' for '-2.0/DST' instead

traduzindo:

 

"ao invés de usar 'America/Sao_Paulo', use '-2.0/DST'"

 

 

tente isso e veja se funciona

Compartilhar este post


Link para o post
Compartilhar em outros sites

retirou a emnsagem relativa a oe erros catalogados sao em portugues e sobre o mysql e esta em ingles e sobre o php....

 

 

[Thu, 11 Dec 2008 15:23:58 -0200] Error 2: mysql_result() [<a href='function.mysql-result'>function.mysql-result</a>]: Unable to jump to row 2 on MySQL result index 16

[Thu, 11 Dec 2008 15:23:58 -0200] Error 2: mysql_result() [<a href='function.mysql-result'>function.mysql-result</a>]: Unable to jump to row 2 on MySQL result index 16

[Thu, 11 Dec 2008 15:23:58 -0200] Error 2: mysql_result() [<a href='function.mysql-result'>function.mysql-result</a>]: Unable to jump to row 2 on MySQL result index 16

[Thu, 11 Dec 2008 15:23:58 -0200] Error 2: mysql_result() [<a href='function.mysql-result'>function.mysql-result</a>]: Unable to jump to row 2 on MySQL result index 16

[Thu, 11 Dec 2008 15:23:58 -0200] Error 2: mysql_result() [<a href='function.mysql-result'>function.mysql-result</a>]: Unable to jump to row 2 on MySQL result index 16

[Thu, 11 Dec 2008 15:23:58 -0200] Error 2: mysql_result() [<a href='function.mysql-result'>function.mysql-result</a>]: Unable to jump to row 2 on MySQL result index 16

[Thu, 11 Dec 2008 15:23:58 -0200] Error 2: mysql_result() [<a href='function.mysql-result'>function.mysql-result</a>]: Unable to jump to row 3 on MySQL result index 16

[Thu, 11 Dec 2008 15:23:58 -0200] Error 2: mysql_result() [<a href='function.mysql-result'>function.mysql-result</a>]: Unable to jump to row 3 on MySQL result index 16

[Thu, 11 Dec 2008 15:23:58 -0200] Error 2: mysql_result() [<a href='function.mysql-result'>function.mysql-result</a>]: Unable to jump to row 3 on MySQL result index 16

[Thu, 11 Dec 2008 15:23:58 -0200] Error 2: mysql_result() [<a href='function.mysql-result'>function.mysql-result</a>]: Unable to jump to row 3 on MySQL result index 16

Compartilhar este post


Link para o post
Compartilhar em outros sites

×

Informação importante

Ao usar o fórum, você concorda com nossos Termos e condições.