I am trying to do a address alert script for my local volunteer fire brigade and I'm stuck.
I have a txt delimited file called preplan.txt containing lines like this:
Line1: REF00001 | NAME1 | ALERTADDRESS1 | LINK2DOWNLOADPDFINFOONADDRESS1 | NOTESONADDRESS1
Line2: REF00002 | NAME2 | ALERTADDRESS2 | LINK2DOWNLOADPDFINFOONADDRESS2 | NOTESONADDRESS2
Line3: REF00003 | NAME3 | ALERTADDRESS3 | LINK2DOWNLOADPDFINFOONADDRESS3 | NOTESONADDRESS3
and so on.
I also have a string named $jobadd which is the address for a job...
What I need to do in php is if the job address is the same ($jobadd) as any of the Alert Addresses in the txt file then display relevant name, address, link and notes.. It needs to also ignore whether it is written in capital letters or not. Basically if $jobadd = a address in the txt file display that info...
I can only seem to echo the last line.