經安全檢測,此網站為安全網站,請放心前往原始網址!

PHP: Get the key from an array in a foreach loop - Stack Overflow

print_r($samplearr) prints the following for my array containing 3 items ... Try this: foreach($samplearr as $key => $item){ print "" . $key .

www.google.com.tw

網址安全性掃描由 google 提供