PHPize Online / SQLize Online  /  SQLtest Online

A A A
Share      Blog   Popular
Copy Format Clear
Copy Clear
Copy Format Clear
<?php $userdb = [ [ 'uid' => '100', 'name' => 'Sandra Shush', 'pic_square' => 'urlof100' ], [ 'uid' => '5465', 'name' => 'Stefanie Mcmohn', 'pic_square' => 'urlof100' ], [ 'uid' => '40489', 'name' => 'Michael', 'pic_square' => 'urlof40489' ] ]; $uid = 100; var_export( collect($userdb)->search(fn($row) => $row['uid'] == $uid) );
Show:  
Copy Clear