Loading:


    http_parse_message
    object http_parse_message ( string $message )


    Analizuje massage (wiadomosc) HTTP  i umieszcza ją  w prostym rekurencyjnym obiekcie



    Parametry

    message

    Łańcych zawieracjąy pojedynczą wiadomość HTTP  lub kilka kolejnych komunikatów HTTP

    Zwracane wartości

    Zwraca hierarchicznyą strukturę objektu analizowanej wiadomości (massage).



    Napisz Artyku³

    Listing


    //Przykłady

    // Example #1 Użycie http_parse_message()

    <?php
    define ('URL', 'http://www.example.com/');
    print_r(http_parse_message(http_get(URL, array('redirect' => 3))));
    ?>

    //Powyższy przykład wyświetli coś podobnego do:

    stdClass object
    (
      [type] => 2
      [httpVersion] => 1.1
      [responseCode] => 200
      [headers] => Array
      (
        [Content-Length] => 3
        [Server] => Apache
      )
      [body] => Hi!
      [parentMessage] => stdClass object
      (
        [type] => 2
        [httpVersion] => 1.1
        [responseCode] => 302
        [headers] => Array
        (
          [Content-Length] => 0
          [Location] => ...
        )
        [body] =>
        [parentMessage] => ...
      )
    )


       

     




    Dodano przez: igor
    Ranga: Administrator serwisu Punktów: 0
    Komentarze użytkowników
      • Tre¶æ komentarza
        Kod do komentarza (opcjonalnie)
        PHP JavaScript MySQL Smarty SQL HTML CSS ActionScript
        Autor
        Token
        token

         

         








    funkcje.net
    Wszelkie prawa zastrzeżone©. | Funkcje.net 2008-2025 v.1.5 | design: diviXdesign & rainbowcolors