I have a program which executes a perl script using the exec command and pipes the result to a file.I then use the file() command to read in the file to an array.I see that the first character in the first line of the resultant file displays a square character and then the desired line.
$somearray = file("file.txt");
My first problem is that I see that the first 79 characters of the line are not displayed,when I echo the value of $somearray[0];
Since the code works for a file where in I manually enter the same values I believe its to do with the square character normally associated with endl in txt documents.
Thanks