php-array printing error
<p>I am trying to print all datas in my array...<br>
But unfortunately it is printing the last two.<br>
But I am echo ing the data in the code..<br>
It is working fine. Whenever I am trying to use <code>var_dump</code> it is showing only last two data.
This is my code</p>

<pre><code>$k=0;
$l=0;
$case_id1=array();
$case_name1=array();
$case_status1=array();
$case_id2=array();
$case_name2=array();
$case_status2=array();

while($k&lt;count($case1) &amp;&amp; $l&lt;count($case2))
{
    if($case1[$k]['case_id']==$case2[$l]['case_id'])
    {
        if($case1[$k]['status']&lt;&gt;$case2[$l]['status'])
        {
            $case_id1[]=$case1[$k]['case_id'];
            $case_name1[]=$case1[$k]['case_name'];
            $case_status1[]=$case1[$k]['status'];
            //echo "case-id: ".$case1[$k]['case_id'];
            //echo "&lt;/br&gt;";
            /*echo "case-name: ".$case1[$k]['case_name'];
            echo "&lt;/br&gt;";
            echo "status: ".$case1[$k]['status'];
            echo "&lt;/br&gt;";*/

            if($case1[$k]['status']=='FAILURE' || $case1[$k]['status']=='ERROR')
            {
                //echo $case1[$k]['status']." message ".$case1[$k]['message'];
                //echo "&lt;/br&gt;";
                //echo "do";

            }

            $case_id2[]=$case2[$l]['case_id'];
            $case_name2[]=$case1[$l]['case_name'];
            $case_status2[]=$case2[$l]['status'];
            /* echo "case-id: ".$case2[$l]['case_id'];
             echo "&lt;/br&gt;";
             echo "case-name: ".$case1[$l]['case_name'];
             echo "&lt;/br&gt;";
             echo "status: ".$case2[$l]['status'];
            echo "&lt;/br&gt;";*/

            if($case2[$l]['status']=='FAILURE' || $case2[$l]['status']=='ERROR')
            {
                //echo $case2[$l]['status']." message: ".$case2[$l]['message'];
                //echo "&lt;/br&gt;";
                //echo "do nothing";

            }
        }

    }
    $k++;
    $l++;

}
var_dump($case_id1);
var_dump($case_name1);
var_dump($case_status1);
var_dump($case_id2);
var_dump($case_name2);
var_dump($case_status2);
</code></pre>

<p>Please help me with this.</p>

<p>output should be like this</p>

<pre><code>case-id: 392
case-id: 435
case-id: 673
case-id: 674
case-id: 675
case-id: 644
case-id: 360
case-id: 528
case-id: 398
case-id: 399
case-id: 400
case-id: 401
case-id: 673
case-id: 674
case-id: 675
case-id: 644
case-id: 673
case-id: 644
case-id: 435
case-id: 584
case-id: 377
case-id: 434
case-id: 644
case-id: 364
case-id: 644
case-id: 782
case-id: 783
case-id: 784
case-id: 785
case-id: 786
case-id: 787
case-id: 673
case-id: 674
case-id: 675
case-id: 527
case-id: 593
case-id: 594
case-id: 595
case-id: 591
case-id: 592
case-id: 477
case-id: 478
case-id: 479
case-id: 493
case-id: 27
case-id: 28
case-id: 29
case-id: 30
case-id: 31
case-id: 32
case-id: 649
case-id: 650
case-id: 377
case-id: 644
case-id: 401
case-id: 644
case-id: 644
case-id: 644
case-id: 435
case-id: 435
case-id: 527
case-id: 399
case-id: 401
case-id: 636
case-id: 594
case-id: 575
case-id: 708
case-id: 355
case-id: 356
case-id: 393
case-id: 394
case-id: 395
case-id: 435
case-id: 398
case-id: 400
case-id: 401
case-id: 593
case-id: 591
case-id: 592
</code></pre>

<p>where i am getting</p>

<pre><code>array
  0 =&gt; string '591' (length=3)
  1 =&gt; string '592' (length=3)
</code></pre>
