I tried to insert file into array and get a specific result from it.
the array_search()
doesn't seem to work.
it looks something like this:
$filepath = "/etc/log/20151026.log";
$logs = file($filepath);
$lo = array($logs);
$search = array_search("username ",$lo);
echo $search;
If I echo only the array $lo
I get the array displayed, yet I can't search through it.
I also tried to extract the array by pieces but a search would be more convenient for the purpose I need.