Everybody! This is important. In a few days, these forums will be moving over to using the totally sweet Discourse platform. To ensure this migration happens smoothly with no loss of content, these forums are currently in a read-only mode. I do apologize for the inconvenience.

There is never a good time to turn the forums off for an extended period of time, but I promise the new forums will be a billion times better. I'm pretty sure of it.

See you all on the other side in a few days, and if you have any (non-technical) questions, please e-mail me at kirupa@kirupa.com. For technical questions, try to find a tutorial that corresponds to what you are looking for and post in the comments section of that page.

Cheers,
Kirupa

Results 1 to 2 of 2

Thread: Array Display Problem

  1. #1

    Array Display Problem

    i have the following array result (with print_r)

    Code:
    [TIMESTAMP] => 2009%2d09%2d11T00%3a12%3a41Z     [CORRELATIONID] => be3a644f8cad9     [ACK] => Failure     [L_ERRORCODE0] => 10001     [L_SHORTMESSAGE0] => Internal%20Error     [L_LONGMESSAGE0] => Timeout%20processing%20request )
    I'd like output it like this:

    Code:
    TIMESTAMP=2009%2d09%2d11T00%3a12%3a41Z
    CORRELATIONID=be3a644f8cad9
    ACK=Failure
    etc...
    Using this
    Code:
    foreach ($httpParsedResponseAr as $value) {
        
        echo "$value<br />\n";
    }
    gets me only the value without the name of the entry

    Code:
    2009%2d09%2d11T00%3a12%3a41Z
    be3a644f8cad9
    Failure
    etc...
    Seems too simple but I cant figure it out
    Any ideas?
    Thanks in advance!
    -Miro

  2. #2
    I found the answer

    foreach ($httpParsedResponseAr as $key=>$value) {

    echo
    "$key=$value<br />\n";
    }

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Home About kirupa.com Meet the Moderators Advertise

 Link to Us

 Credits

Copyright 1999 - 2012