I am trying to convert a text file into a string, then into an array and then finaly print each of the values (words) into separate 'a' holders.
The .txt file contains one line of text.
I have tried it through a for loop, like so:
$lines = file_get_contents('test.txt', FILE_USE_INCLUDE_PATH);
$words = explode(" ", $lines);
for ($x = 1; $x >= 100; $x++){
print '<a id="word$x">'$words[$x]'</a>';
}
But that doesnt work. I am sure that I am just missing something basic, but I have tried and failed so many times, that I need others opinions and advice.