I am loading a text file into an array:
<?php
$filename = "data.txt";
$array = file($filename, FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);
?>
The file contains certain lines, that start with the word "Data". Those lines are loaded as separate values in the array.
What I wanna do is extract only those values from the array and save those as a separate file, each one on a new line.
How would I go about searching for those specific values in the array and doing the above?