[03fe3a]: koha-offline-circulation-client / functions.php  Maximize  Restore  History

Download this file

19 lines (19 with data), 403 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
<?php
/**
* Remove a value from a array
* @param string $val
* @param array $arr
* @return bool True if found and removed, false if not found.
*/
function array_remove_value($val, &$array) {
$i = array_search( $val, $array );
if ( $i !== false ) {
$array = array_merge(
array_slice( $array, 0, $i ),
array_slice( $array, $i+1)
);
return true;
}
return false;
}
?>