完全不懂什么意思
Code
<%@ Page Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script runat="server">
</script>
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
<title>XmlDataSource</title>
</head>
<body>
<form id="form1" runat="server">
<asp:DataList ID="DataList1" Runat="server" DataSourceID="XmlDataSource1">
<HeaderTemplate>
<table border="1" cellpadding="3">
</HeaderTemplate>
<ItemTemplate>
<tr><td><b><%# XPath("title") %></b><br />
<i><%# XPath("pubDate") %></i><br />
<%# XPath("description") %></td></tr>
</ItemTemplate>
<AlternatingItemTemplate>
<tr bgcolor="LightGrey"><td><b><%# XPath("title") %></b><br />
<i><%# XPath("pubDate") %></i><br />
<%# XPath("description") %></td></tr>
</AlternatingItemTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:DataList>
<asp:XmlDataSource ID="XmlDataSource1" Runat="server"
DataFile="http://www.hanselman.com/blog/SyndicationService.asmx/GetRss"
XPath="rss/channel/item">
</asp:XmlDataSource>
</form>
</body>
</html>
posted @
2009-01-15 17:08
jianlinglo
阅读(
185)
评论()
编辑
收藏
举报