Index of Array Values in PHP

Q

How Values in Arrays Are Indexed in PHP?

✍: FYIcenter.com

A

Values in an array are all indexed their corresponding keys. Because we can use either an integer or a string as a key in an array, we can divide arrays into 3 categories:

  • Numerical Array - All keys are sequential integers.
  • Associative Array - All keys are strings.
  • Mixed Array - Some keys are integers, some keys are strings.

 

Adding Values to an Array without Keys in PHP

Data Types of Array Keys in PHP

Understanding PHP Arrays and Their Basic Operations

⇑⇑ PHP Tutorials

2017-02-03, 2525🔥, 0💬