Skip to first unread message

HD IPTV

unread,
Apr 30, 2015, 7:35:41 PM4/30/15
to mitappinv...@googlegroups.com
Hi there i have a website that shows live tv guide data i have created a dynamic xml api with php and sql

wen the url is called it displays xml code shown bellow

<categorys>
<category>
<title>News</title>
<code>111</coode>
</category>
<category>
<title>Sports</title>
<code>111</coode>
</category>
<category>
<title>Movies</title>
<code>111</coode>
</category>
</categorys>

how can i read this from the web eliment and add each item into a list of somesort so that wen a user clicks on a item it then creates another request to the same url but with the code from the category in the xml file ?

Ethan

unread,
Apr 30, 2015, 10:26:43 PM4/30/15
to mitappinv...@googlegroups.com
Hi, 

Can you give us the url so that we can try? 

In the meantime, you can try the event, "when Web1.GotText" and display the parameter, "responseContent"

Taifun

unread,
May 1, 2015, 9:57:30 AM5/1/15
to mitappinv...@googlegroups.com
use the Web.XmlDecode block to convert the result into a list of lists
then use the lookup in pairs block to extract the relevant part, in your case the categorys
now you can use a for each in list loop to loop through the list

see also

Taifun

Trying to push the limits of App Inventor! Snippets and Tutorials from Pura Vida Apps by Taifun.         

Abraham Getzler

unread,
May 1, 2015, 2:25:44 PM5/1/15
to mitappinv...@googlegroups.com

Abraham Getzler

unread,
May 1, 2015, 2:28:29 PM5/1/15
to mitappinv...@googlegroups.com
P.S.  If you're generating the XML, you might want to fix
<code> ...</coode>
ABG

Reply all
Reply to author
Forward
0 new messages