PHP traversal problems, trouble passing by-php Tutorial

Source: Internet
Author: User
Array of PHP traversal problems and troubles:
Array ([doctorcomment] => Array ([0] => Array ([status] => success [strcommenttype] => 1 [strcommentcontent] => saradb [strcreatetime] => [strusername] => wanhui [struserip] => 121.101.220.243 [strmobile] => 13910527603) [1] => Array ([status] => success [strcommenttype] => 2 [strcommentcontent] => sdfsd [strcreatetime] => 2014-08-20 [strusername] => sdfds [struserip] = & gt; 343.2432.432 [strmobile] = & gt; 18600085268) [2] => Array ([status] => success [strcommenttype] => 9 [strcommentcontent] => fsfddsf [strcreatetime] => 2014-08-20 [strusername] => sdfdsdfd [struserip] => 343.2432.432 [strmobile] => 18600085268 )))

 ". $ Value_3 ['strcommentcontent']."

"; Echo"
"; Echo" from ". $ value_3 ['strusername']." ". $ value_3 ['strcreatetime']."> "; echo"
"; Echo" ";}Else {echo" null date ";}}}?>

Please ask, why can't I get the value 3? the value 3 is the value 1.


Reply to discussion (solution)

3. where?

Foreach ($ arrGetDoctorComment as $ arr_3) {if ($ arr_3 ['strcommenttype'] = "9") {echo"

". $ Value_3 ['strcommentcontent']."

"; Echo"
"; Echo" from ". $ value_3 ['strusername']." ". $ value_3 ['strcreatetime']."> "; echo"
"; Echo" ";}Else {echo" null date ";}}

3. where?

Foreach ($ arrGetDoctorComment as $ arr_3) {if ($ arr_3 ['strcommenttype'] = "9") {echo"

". $ Value_3 ['strcommentcontent']."

"; Echo"
"; Echo" from ". $ value_3 ['strusername']." ". $ value_3 ['strcreatetime']."> "; echo"
"; Echo" ";}Else {echo" null date ";}}



Sorry, the error message is 2nd. I want to extract 2. the value of [strcommenttype] is 9.

Isn't your code correct? what's the problem?

Isn't your code correct? what's the problem?

I did not display it in the area where "Show 2". it shows 0 information.

Isn't your code correct? what's the problem?


 
  • High praise (100)
  • Medium rating (1000)
  • Negative rating (1000)
  • ". $ Value_3 ['strcommentcontent']."

    "; Echo"
    "; Echo" from ". $ value_3 ['strusername']." ". $ value_3 ['strcreatetime']."> "; echo"
    "; Echo" ";}Else {echo" null date ";}}}?>


    From


  • ". $ Value_2 ['strcommentcontent']."

    "; Echo"
    "; Echo" from ". $ value_2 ['strusername']." ". $ value_2 ['strcreatetime']."> "; echo"
    "; Echo" ";}Else {echo" null date ";}}}?>
  • ". $ Value_3 ['strcommentcontent']."

    "; Echo"
    "; Echo" from ". $ value_3 ['strusername']." ". $ value_3 ['strcreatetime']."> "; echo"
    "; Echo" ";}Else {echo" null date ";}}}?>

$ ArrGetDoctorComment value can be found at the top.
All the information displayed in tab_con_3, tab_con_2, and tab_con_1 is "Sada"

Each section of you is if ($ value_3 ['strcommenttype'] = "3 "){
The results are the same.

Each section of you is if ($ value_3 ['strcommenttype'] = "3 "){
The results are the same.


I have already seen this problem. after the modification, the results are still the same. each labe has 1 content. let's take a look at it.
http://m.gstzy.cn/comment/doctorcomment.php?doctorid=335

Your #5 code cannot be connected.
However, it cannot be ruled out that 7th rows of unclosed li are playing a strange role in your browser.

Your #5 code cannot be connected.
However, it cannot be ruled out that 7th rows of unclosed li are playing a strange role in your browser.


 
  • ". $ Value_1 ['strcommentcontent']."

    "; Echo"
    "; Echo" from ". $ value_1 ['strusername']." ". $ value_1 ['strcreatetime']."> "; echo"
    "; Echo" ";}Else {echo" null date ";}}}?>
  • ". $ Value_2 ['strcommentcontent']."

    "; Echo"
    "; Echo" from ". $ value_2 ['strusername']." ". $ value_2 ['strcreatetime']."> "; echo"
    "; Echo" ";}Else {echo" null date ";}}}?>
  • ". $ Value_3 ['strcommentcontent']."

    "; Echo"
    "; Echo" from ". $ value_3 ['strusername']." ". $ value_3 ['strcreatetime']."> "; echo"
    "; Echo" ";}Else {echo" null date ";}}}?>


That is, the connection problem is not found. I closed every tab. let's take a look at the problem. thank you.



  • Don't you think there is a problem?



  • Don't you think there is a problem?



    Thank you.
  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.