����������
WEB - ������

www.spravkaweb.ru Rambler's Top100
 ï¿½ï¿½ ����������: �������/PHP/������������ � ��������� ������.������� ��������� ������Ðàñïå÷àòàòü 
�������
�������
����� ���
HTML
JavaScript
VBScript
CSS
Flash
Perl
PHP
MySQL
SSI
VRML
�������������
������
Download
�����
��������
������
�������� ���
�����:
��������
Subscribe.Ru:

PHP

<--����� | ��������� � ������ | ������-->
������������ � ��������� ������
������� ��������� ������
error_log
������� ��������� �� ������.

��������� :
int error_log(string message, int message_type [, string destination [, string extra_headers]])

���������, ���������� ���� ��������, ����� ���� ���������� � ������ ��������� ��������� web-�������, ���� TCP ��� � ����.
� ������ ��������� message ����������� ���� ���������� ���������. �� ������ ��������� message_type - ���� ��� ������ ���� ����������.
���������� ������������ ���������� ����������:

  • 0 - ��������� ��������� � ��������� ������ ������� (����) �������� ��������� ��������� ������������ error_log.
  • 1 - ��������� ������������ �� ����������� �����, �� ������, ���������� � ��������� destination. ��� ������������ ��� ���������, ������������ ��������� �������� extra_headers, � ������� ����� ������� �������������� ��������� (��� � ������� mail()).
  • 2 - ��������� ���������� ����� ����������� �������. ��� �������� ������ � ������, ���� �������� ��������� ������� ��� �������� � ����� ������������. ��� ����� ����� ������ ���� ��������� ����� ����� (��� ��� ��� IP �����) � ���� ������, ������� ����� ��������� ��������� �������. ��� ����� ������� � ��������� destination ��� ���������� ������������.
  • 3 - message ����������� � ����� ����� destination.
    if(!Ora_London($username, $password)) {
      error_log("������ Oracle ����������!", 0);
    };
    
    if(!($foo = allocate_new_foo()) {
      error_log("������ �������� FOO!", 1, "[email protected]");
    }
    
    // other ways of calling error_log():
    error_log("� ��� ������!", 2, "127.0.0.1:7000");
    error_log("� ��� ������!", 2, "localhost");
    error_log("� ��� ������!", 3, "/var/tmp/my-errors.log");
    

  • error_reporting
    ��������� ����� ���������� ������.

    ��������� :
    int error_reporting([int level])

    ������� error_reporting() ���������� ���������� ��������� ���� ���������� ������. ���� ������ ��������, �� ������ �������������� ��. � ��������� ����� ��������� ���������, ����� ��� ������� �����. ���������� ������������ ��������� ������ ��������� ��������, ����� ��������� ������������� � �������� �������� PHP.
    error_reporting(2039); // � PHP ���������� E_ALL ^ E_NOTICE
    error_reporting(E_ALL ^ E_NOTICE); // ��������� �� ���������
    error_reporting(0); // ��������� ��������� �� �������
    // ����� ������ ����������
    error_reporting(E_ERROR | E_WARNING | E_PARSE);
    // ����� �������� � ����������� ����������
    error_reporting(E_ERROR | E_WARNING | E_PARSE | E_NOTICE);
    error_reporting(E_ALL); // �������� ��� ������
    

    restore_error_handler
    �������������� ����������� ����������� ������.

    ��������� :
    void restore_error_handler()

    ��� ������� ������������� � �������� ������� ����������� ������ ��, ������� ���� ������� �� ���������� ������ ������� set_error_handler(). ���������� ������������ ����� ���� ����� ������������� ���������������� ���������� ��� ���������� ���������� PHP.

    trigger_error
    ��������� ������.

    ��������� :
    void trigger_error(string error_msg [, int error_type])

    ���� �������� �������, ������������� ��� ��������� ������, � ������ ������������ � ���� � ������������ ������. ������� �������� ������������ ������ ���������������� ���� ������ ( ��������� �������� E_USER), � �� ���������, ���� �� ������ ��� ������ error_type, �� ��������� E_USER_NOTICE.

    �������� �������������� ������� ����������� ��������� � ��������� ������ � �������������� ��������.
    if(assert($divisor == 0))
      trigger_error ("������ ������ �� 0 ", E_USER_ERROR);
    

    user_error
    ������� ������� trigger_error().

    ��������� :
    void user_error(string error_msg [, int error_type])
    �� ���������� ����� ����� ������� "PHP 4. ����������� ����������."
    www.piter.com
    ������ / � ����������
     
    Download
    Ñêà÷àòü ñïðàâî÷íèê ïî PHP
    ��� ������:
    05.07.2004
  • � ������� PHP ��������� ��������� ������� ��� ������ � ���������� (���������� GD):
    imagetypes(), ...
  • � ������� JavaScript ��������� �������� �� ����� D, E, F, H, I
  • � ������� ������ ��������� ������, �������������� ��� �������� � html-�������� ��������� MS Office (Word, Excel � �.�.)
  • �����������:
    ��� ��� ������ ����� �� �������� � �����������:
    ��� ��������.
    ������ �� ��������.
    ���� ��������.
    �������� �������� �������.
    �� ��� ������� �������.
    � ����������� ���� ������.
    � ��� ��� �����.
    ������.
    ��������:
    Rambler's Top100
    Ñäåëàòü ñòðàíèöó ñòàðòîâîé ������� �������� ���������
    Äîáàâèòü ñòðàíèöó â èçáðàííîå �������� ���� � ���������
    Ñîîáùèòü îá íàéäåííîé îøèáêå �������� �� ������