Reply to Re: on error

Your name:

Reply:


Posted by Schraalhans Keukenmeester on 05/19/07 09:05

At Sat, 19 May 2007 07:19:18 +0000, Robertu let his monkeys type:

> "Erwin Moller"
> WROTE:
>
>> Hi Robertu,
>>
>>> $connection = mysql_connect("12.34.5.67.89", "Sql111111","hELLOWORLD");
>>
>> mysql_connect returns a value.
>> Check at www.php.net for details.
>>
>> In this case FALSE is returned if the mysql_connect fails.
>> So you'll end up with something like this:
>> $connection = @mysql_connect("12.34.5.67.89", "Sql111111","hELLOWORLD");
>> if ($connection === FALSE){
>> echo "problem connecting...";
>> exit;
>> }
>
> Hi Erwin and tank you very much
> NOW I wrote
> $connection = @mysql_connect("12.34.5.67.89", "Sql111111","hELLOWORLD");
> if ($connection === FALSE)
> {
> header("www.pippo.es/");
> exit();
> }
>
> can it work?
>
Use header('Location:http://www.pippo.es');

And make sure there is NO output by your script before sending the
custom header, as that will cause a header to be already sent.

HTH
Sh.

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация