homepage Welcome to WebmasterWorld Guest from 174.129.130.202
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / XML Development
Forum Library, Charter, Moderators: httpwebwitch

XML Development Forum

    
links in XML?
BabyJai




msg:4430548
 11:37 am on Mar 18, 2012 (gmt 0)

<Members>
<Member>
<Name>whatever</Name>
<RecentPointsSpent>20</RecentPointsSpent>
<RecentPointsEarned>40</RecentPointsEarned>
<CurrentPoints>120</CurrentPoints>
<LastItems><a href="test">whatever</a></LastItems>
</Member>
</Members>


now when i make my javascript this is what i got going on.

<div spry:region="ds1">
<table>
<tr>
<th spry:sort="Name">Name</th>
<th spry:sort="RecentPointsSpent">RecentPointsSpent</th>
<th spry:sort="RecentPointsEarned">RecentPointsEarned</th>
<th spry:sort="CurrentPoints">CurrentPoints</th>
<th spry:sort="LastItems">LastItems</th>
</tr>
<tr spry:repeat="ds1">
<td>{Name}</td>
<td>{RecentPointsSpent}</td>
<td>{RecentPointsEarned}</td>
<td>{CurrentPoints}</td>
<td>{LastItems}</td>
</tr>
</table>
</div>


how come it doesnt show the link? It shows it as undefined?

 

Dijkgraaf




msg:4430676
 11:43 pm on Mar 18, 2012 (gmt 0)

For starters your XML is invalid as you are using the reserved characters of < and >

Maybe you should split your LastItems so you have one that contains the text and the other the URL, and you then have your javascript write that into the <a href="{LastItemsURL">LastItems</a>

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / XML Development
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved