one typo: the foreach loop should assign the indexed mls number to $mls like so: // output your property info foreach ($propertyArray as $mls => $property) {