Take the 2-minute tour ×
Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.

I have this array:

array (size=2)
  0 => 
    array (size=1)
      0 => 
        object(stdClass)[1]
          public 'username' => string '3adi jeddan' (length=11)
          public 'userimage' => string 'file_4981.jpg' (length=13)
          public 'date' => int 1373508347
          public 'postid' => string '114' (length=3)
          public 'type' => string 'comment' (length=7)
          public 'notify' => string '1' (length=1)
  1 => 
    object(stdClass)[2]
      public '1' => 
        object(stdClass)[3]
          public 'username' => string '3adi jeddan' (length=11)
          public 'userimage' => string 'file_4981.jpg' (length=13)
          public 'date' => int 1373508355
          public 'postid' => string '114' (length=3)
          public 'type' => string 'comment' (length=7)
          public 'notify' => string '1' (length=1)

I need to change the value of notify from 1 to 0, but I can't any more. Please help me.

share|improve this question
    
$array[0][0]->notify = "1" ? –  DontVoteMeDown Jul 11 '13 at 11:59
    
Its array of object. –  Yogesh Suthar Jul 11 '13 at 11:59
    
@WajdiJurry echo $array[0][0]->username; should work have u tried ? –  Prix Jul 11 '13 at 12:02
    
Thank you so much DonyVoteMeDown. It works :) –  Wajdi Jurry Jul 11 '13 at 12:02
    
Thank you so much Prix. It works :) –  Wajdi Jurry Jul 11 '13 at 12:03

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.