Add countable for php