Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
配列の最初の行にアクセスする必要がありますが、次のようにはなりません:
print_r($array[0]) ;
このようなものと組み込み:
echo first($array) ;
phpにそのようなものはありますか?
$first_value_of_array = reset($array); // First Element's Value $first_key_of_array = key($array); // First Element's Key
お役に立てれば。:)