spyros1234 Posted March 14, 2007 Share Posted March 14, 2007 Hello I am trying to make a script that will read a .txt file and it will export the text that is written in the file in separate variables I have upload the txt file www.istografos.com/gari/orders3.txt I will try to describe the file but will be better if you have the time to open it. The text is written in the same order in each txt file. The problem is the text length will be indefinable. And something else the txt file is an export from a ERP system so I can’t modify the text. I have to deal it as it is. If you have any idea please HELP Quote Link to comment Share on other sites More sharing options...
zq29 Posted March 14, 2007 Share Posted March 14, 2007 You can use file() or file_get_contents() to read the content of a text file into a variable. You can then loop through the data and assign it to individual variables with the explode() function. Check the manual on how to use these functions. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.