Welcome Guest, Not a member yet? Register   Sign In
To those array experts
#5

I put another for loop around the above
for($i = 0; $i < $totalElements; $i++) {
  echo $i;
  print_r($data['dates2'][$i]
);
and i get

A PHP Error was encountered
Severity: Notice
Message: Undefined offset: 0
Filename: controllers/diet_plan.php

Line Number: 723
1Array ( [23] => Array ( [cust] => 6 [item_date] => 2015-08-05 [item_hours] => 2.00 [item_amount] => 37.00 [cost] => 74 [total_cost] => 74 [cluster_tasks] => Array ( ) [jobs] => Array ( [name] => 3 Aireys Street Aireys Inlet ) ) )

so it isn't putting the first output into [0] of array - interesting - but i am not sure how to fix it because it looks like it should work to me...! please could u look for the line that i must have wrong somewhere - thank you
}
Reply


Messages In This Thread
To those array experts - by scoobie - 08-22-2015, 11:47 PM
RE: To those array experts - by jLinux - 08-23-2015, 12:21 AM
RE: To those array experts - by scoobie - 08-23-2015, 06:01 AM
RE: To those array experts - by pdthinh - 08-23-2015, 10:02 AM
RE: To those array experts - by scoobie - 08-23-2015, 04:20 PM
RE: To those array experts - by RobertSF - 08-23-2015, 07:26 PM
RE: To those array experts - by scoobie - 08-24-2015, 02:03 AM
RE: To those array experts - by RobertSF - 08-24-2015, 10:57 AM
RE: To those array experts - by mwhitney - 08-24-2015, 02:18 PM
RE: To those array experts - by scoobie - 08-26-2015, 03:46 PM
RE: To those array experts - by scoobie - 08-26-2015, 11:17 PM
RE: To those array experts - by RobertSF - 08-27-2015, 09:00 AM
RE: To those array experts - by mwhitney - 08-27-2015, 01:10 PM



Theme © iAndrew 2016 - Forum software by © MyBB