David wyatt
Posts: 0
Joined: Mon Sep 15, 2014 7:12 pm

how to split elements of rss feed

Hi,

Im trying to create an app that uses rss feeds. When i follow the tutorial i get all the elements (articles in a list) but the links are generated from one and link to the feeds website. I want the links to load a page inside the app. By not mapping the service to the grid I have managed to get the first element to work, the issue is i cant see the other elements. Is there a way to link each element from the same rss feed to different componenets?

Thank you Image

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

how to split elements of rss feed

Hi David -

Sorry, not sure I understand what other element you can't find here:
[quote:]
By not mapping the service to the grid I have managed to get the first element to work, the issue is i cant see the other elements.
[/quote]

[quote:]
Is there a way to link each element from the same rss feed to different componenets? [/quote]
You have a response from your service and you can map the response to the different components on the page.

David wyatt
Posts: 0
Joined: Mon Sep 15, 2014 7:12 pm

how to split elements of rss feed

Hi Stepanov, thank you for the help.
I'm trying to build a news app. When i followed the tutorial all the articles appear but the link generated takes you to the website. I want the link to each article to go to different pages inside the app. The issue is you map to one component in a grid which then duplicates for all the articles.
If I dont map to the grid I only get the first article, how do I then map the second article to its own components?

Evgene Karachevtsev
Posts: 12
Joined: Mon Apr 28, 2014 1:12 pm

how to split elements of rss feed

Hello David,

Could you please show us screenshot of your mapping?

David wyatt
Posts: 0
Joined: Mon Sep 15, 2014 7:12 pm

how to split elements of rss feed

HI,

I have only mapped to the components not the grid at the moment.
I was thinking i could map to the grid but use the following javascript toonly show the second article
if (count !=1 {
element.hide();
} else {
count++;
}
with count being set to zero, this way it should hide all articles except the second one
Image

David wyatt
Posts: 0
Joined: Mon Sep 15, 2014 7:12 pm

how to split elements of rss feed

HI,

looks like i managed to get it too work. instead of

if (count !=1) {
element.hide();
} else {
count++;
}

i used

if (count ==0 {
element.hide();
count++;
} else if (count ==2 {
element.hide();
} else {
count++;
}

to do third article it was

if (count ==0 {
element.hide();
count++;
} else if (count ==1 {
element.hide();
count++;
} else if (count ==3 {
element.hide();
} else {
count++;
}

Illya Stepanov
Posts: 0
Joined: Mon Mar 18, 2013 8:48 am

how to split elements of rss feed

Thanks for the update, David.

Return to “Issues”