php Multidimensional Array pushing

H0rn

New Member
Is it possible to array_push to a multidimensional array?Creating the array using: \[code\]$ObjectArray = array();$ShiftArray = array($ObjectArray);$WeekShiftArray = array($ShiftArray);$MasterShiftArray = array($WeekShiftArray);\[/code\]And trying to push to the array using \[code\]array_push($MasterShiftArray[$last_monday_from_date][$CurrentShift->Offset][$CurrentShift->Shift], $CurrentShift);\[/code\]But I'm getting:Warning: array_push() expects parameter 1 to be array, object given in /opt/lampp/htdocs/sandboxj/blog/wp-content/plugins/Shifty/AddShift.php on line 94Any help would be appreciated.
 
Back
Top