How can i make the contents of a file the elements of an array.
For example, I have a file named log.log which might contain this and nothing else
I've tried to make an array where the elements would be $array[0]="somestring" $array[1]="anotherstring" etc etc like thissomestring, anotherstring, newstring,
Code: Select all
$array = array ( include('log.log') );
echo $array[0];as what is apparently the first element when it should be just "somestring".somestring, anotherstring, newstring, 1
Am I doing this right?
Thanks