I am trying to pull a specific bit of data out of the last line of a text file to be able to display it on it's own. For example I want to pull the rainfall data out of the following file:
#date #time #blah #rainfall #blah #blah
200813 1234 1234 0.5 1234 1234
200813 1235 1234 1.2 1234 1234
200813 1236 1234 3.5 1234 1234
200813 1237 1234 0.2 1234 1234
200813 1238 1234 0.1 1234 1234
And I want to use the data in this way on a web page:
Rainfall predicted now: 0.1mm
So all I need is that 0.1 figure out of the last line. As the file is remote and new lines are added at the bottom of the file, I only ever need the last line.
Can someone please help, I have been wracking my brains over this for days.