PHP Programing language

R4R® PHP
(追記) (追記ここまで)
(追記) (追記ここまで)
array_current() and array_pos() Function in PHP
(追記) (追記ここまで)
(追記) (追記ここまで)

array_current()

The current() function returns the value of the current element in an array.

Syntax:
current(array)

In above syntax, "array" specifies the array to use

Example:

<?php
$vehicle = array("Car", "Scooter", "Motorcycle", "Truck");
echo current($vehicle)."<br>";
?>

Output:

Car

(追記) (追記ここまで)

array_pos()

The pos() function returns the value of the current element in an array.

Syntax:
pos(array)

In above syntax, "array" specifies the array to use.

Example:

<?php
$vehicle = array("Car", "Scooter", "Motorcycle", "Truck");
echo pos($vehicle)."<br>";
?>

Output:

Car

(追記) (追記ここまで)
Copyright ©2021-22 r4r.co.in, all rights reserved. Theguestspost.com
Sitemap
Career
Post comment
About us
Subscription
Unsubscription

AltStyle によって変換されたページ (->オリジナル) /