Hello,
I'm stuck...been trying to come with asimple solution for hours. Here's my deal...
I have TXT file uploads going into my server from random users of my website...ALL uploaded TXT files are formatted the same way:
<file>polly_01.jpg</file> <cap>This is a test caption for image 1</cap>
<file>polly_02.jpg</file> <cap>This is a test caption for image 2</cap>
<file>polly_03.jpg</file> <cap>This is a test caption for image 3</cap>
<file>polly_04.jpg</file> <cap>This is a test caption for image 4</cap>
<file>polly_05.jpg</file> <cap>This is a test caption for image 5</cap>
Now, what I'd like to do is get some help with the code that will do the following:
Read the file
Parse the data from each line...in between the tags; example: polly_01.jpg, This is a test caption for image 1
Then put that data into my MySQL database, line by line.
If anyone can help I'd greatly appreciate the assistance!
Thanks in advance! All coding examples are VERY welcome!