A
          / \      _             Play Now                         Nemesis on fb
          | |     | |  _______   _        _   _______    _______   _    _______
          | |\    | | |   ____| |  \    /  | |   ____|  /   ____| | |  /   ____|
 /-------/-------------------------------------------------------------------,
O= Home <=XX|  About  News  Pics  Adventurers  Wizards  Download  Connect     >
 \-------\-------------------------------------------------------------------'
          | |   \   | |  |____  | |      | | |  |____   ___ \  \  | |  ___ \  \
          | |     \_| |_______| |_|      |_| |_______| |_______/  |_| |_______/
          \ /
           V  

Documentation Area

Document Path: /doc/efun/map_array


mixed *map_array(mixed *arr, string fun, object ob, mixed extra)

Returns an array holding the items of <arr> mapped through ob->fun().
The function <fun> in <ob> is called for each element in <arr> with that
element as parameter. A second parameter <extra> is sent in each call if
given. Principal function: 
	foreach (index) arr[index] = ob->fun(arr[index],extra);

The value returned by ob->fun(arr[.index.], extra) replaces the existing 
element in the array. If <arr> is not an array, then 0 will be returned.

See also:


This page was generated in LPC

Imprint / Impressum