How to insert this information into a table?

Hi I’m currently reading a file remotely using the

 

network.request( “http://www.somewebsite.com”, “GET”, networkListener )

 

on the networkListerner event.response I’m getting the information in this way:

Id:3108201414;

Repeat:1;

Link:https://itunes.apple.com/app/something;

Itunesid:9059;

Image:http://imageshack.com/a/.png;

Appname:com.something;Id:1908201415;

Repeat:1;

Link:https://itunes.apple.com/something;

Itunesid:844;

Image:http://imageshack.com/a/.png;

Appname:com.something;Id:140820149;

 

I want to be able to use this information. How can I insert this into a table so I can later use this information?

Google for “Lua string split”.  You will find several functions that will let  you split a string based upon a character.  In your case, you can split the strings on the semi-colon at the end of each line.  This would put each line in an array.  Then you can then build up a key-value pair table by copying the items out of the array based table.

Rob

Google for “Lua string split”.  You will find several functions that will let  you split a string based upon a character.  In your case, you can split the strings on the semi-colon at the end of each line.  This would put each line in an array.  Then you can then build up a key-value pair table by copying the items out of the array based table.

Rob