Is there a more efficient way to filter large arrays than preg_match()?
- by hozza
I have a log that our web application builds. Each month it contains around 16,000 entries of a string with about the average sentence worth of text.
To filter/search through these in our admin panel the script uses preg_match() but this seems to be taking ages and timing out on the 30sec limit. I have isolated that it is indeed the preg_match() that causes the time out.
Is there a more efficient way to search through values in a large array for a users input?