+ -
当前位置:首页 → 问答吧 → [求助]如何在一个html中调用几个xml文件?

[求助]如何在一个html中调用几个xml文件?

时间:2005-12-07

来源:互联网

想在同一个html中调用几个xml文件.
应该怎样写这个html呢?
用数据岛大概不行. 有没有其他方法.
最好给个例子..
cd.xml
<?xml version="1.0"?> <CATALOG> <CD> <TITLE>Empire Burlesque</TITLE> <ARTIST>Bob Dylan</ARTIST> <COUNTRY>USA</COUNTRY> <COMPANY>Columbia</COMPANY> <PRICE>10.90</PRICE> <YEAR>1985</YEAR> </CD> <CD> <TITLE>Hide your heart</TITLE> <ARTIST>Bonnie Tylor</ARTIST> <COUNTRY>UK</COUNTRY> <COMPANY>CBS Records</COMPANY> <PRICE>9.90</PRICE> <YEAR>1988</YEAR> </CD> <CD> <TITLE>Greatest Hits</TITLE> <ARTIST>Dolly Parton</ARTIST> <COUNTRY>USA</COUNTRY> <COMPANY>RCA</COMPANY> <PRICE>9.90</PRICE> <YEAR>1982</YEAR> </CD> <CD> <TITLE>Still got the blues</TITLE> <ARTIST>Gary More</ARTIST> <COUNTRY>UK</COUNTRY> <COMPANY>Virgin redords</COMPANY> <PRICE>10.20</PRICE> <YEAR>1990</YEAR> </CD> <CD> <TITLE>Eros</TITLE> <ARTIST>Eros Ramazzotti</ARTIST> <COUNTRY>EU</COUNTRY> <COMPANY>BMG</COMPANY> <PRICE>9.90</PRICE> <YEAR>1997</YEAR> </CD> </CATALOG>
   提示:您可以先修改部分代码再运行

rss.xml
<?xml version="1.0" > <?xml-stylesheet type="text/css" href="rss.css"?> <rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"> <channel> <title> T's blog </title> <link> http://www.uiokyu.com/ </link> <description> Uiokyu </description> <generator> RainbowSoft Studio Z-Blog 1.4 SP3 Build 51008 </generator> <language> zh-CN </language> <copyright> Copyright uiokyu.com Some Rights Reserved. </copyright> <pubDate> Mon, 05 Dec 2005 00:32:15 +0800 </pubDate> <item> <title> web2.0的先驱与先烈 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/48.html </link> <pubDate> Sun, 04 Dec 2005 20:35:04 +0800 </pubDate> <guid> http://www.uiokyu.com/post/48.html </guid> <description> <![CDATA[ 长江后浪推前浪,前浪死在沙滩上,Web2.0在中国上演得轰轰烈烈,国外的Web2.0网站挨个被收购或者得到大笔钱融资,不过,年底了,究竟谁能度过年关,明年还成为弄潮儿呢?或者说,明年这个时候,这批web2.0网站还能剩几个?<br/><br/>先驱很多都会演变成先烈,市场不认可,用户不认可,再牛B的项目也会死掉,如果你经常看中国足球,总会听见再世界杯外围赛中,教练说:“我们还活着”,是啊,活着多不容易啊,可是很多人就是挨不过去,先驱就成了先烈。 ]]> </description> <category> Personal </category> </item> <item> <title> 军用聊天工具???? </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/47.html </link> <pubDate> Sun, 04 Dec 2005 20:33:12 +0800 </pubDate> <guid> http://www.uiokyu.com/post/47.html </guid> <description> <![CDATA[ ... ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> 盛大易宝 亲密接触 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/46.html </link> <pubDate> Sat, 03 Dec 2005 11:01:40 +0800 </pubDate> <guid> http://www.uiokyu.com/post/46.html </guid> <description> <![CDATA[ 第一时间内拿到盛大EZPOD(盛大易宝),于是便来了一个“第一次的亲密接触”,让我们来看一看由网游巨头“盛大”带给大家的新体验! ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> 一只鸟与另一只鸟催人泪下的故事 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/45.html </link> <pubDate> Sat, 03 Dec 2005 10:56:11 +0800 </pubDate> <guid> http://www.uiokyu.com/post/45.html </guid> <description> <![CDATA[ 星期六的下午,港南的天气阴霾,很多的家燕,成群停留在马路上觅食戏耍,看着来往的大货车 ,突然,一辆呼啸而过的大货车开过,地上只看到一团黑影留着,不幸又发生了…… ]]> </description> <category> Personal </category> </item> <item> <title> 星际争霸:幽灵 预览影片片断 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/44.html </link> <pubDate> Fri, 02 Dec 2005 17:32:26 +0800 </pubDate> <guid> http://www.uiokyu.com/post/44.html </guid> <description> <![CDATA[ 暴雪官方今天首次展示了一段《星际争霸:幽灵》的预览影片片断,在这段影片中,女主角Nova为观众上演了一出如何隐身潜入一个人类基地并制造了一场大混乱的好戏。关注这款处于暴雪进行时游戏的朋友可以借机对游戏的操作方式有一定了解,除了FPS游戏通用的枪械射击外,女主角Nova还展示了如何背后暗杀(有些暴力阿,估计要分级了)、攀爬、隐身走路、操纵机器人、开大卡车等特殊技能。不知道《星际争霸:幽灵》能否延续"暴雪出品必属精品"的口号,相信游戏正式发布后就会大白于天下了。影片下载地址(33.4M):http:... ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> 赚钱多少是衡量男人有用与否的唯一标准? </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/43.html </link> <pubDate> Fri, 02 Dec 2005 14:50:10 +0800 </pubDate> <guid> http://www.uiokyu.com/post/43.html </guid> <description> <![CDATA[ 前段时间,我在一位朋友的《若重新来过,我还是否再读博士》一文的后面见到这样一段回复,大意是为自己的博士丈夫没有自己赚钱而认为其没用,郁闷不已。 <br/> 看完这一回复,沉吟良久,一直思考这样一个问题:赚钱多少是衡量男人有用与否的唯一标准?这个社会,生而为男人,就注定了与女人不同的价值取向 ]]> </description> <category> Personal </category> </item> <item> <title> 盛大'盒子'开卖.价格458元 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/42.html </link> <pubDate> Fri, 02 Dec 2005 13:41:12 +0800 </pubDate> <guid> http://www.uiokyu.com/post/42.html </guid> <description> <![CDATA[ 昨天(12月1日),盛大宣布,电脑宽带娱乐中心产品盛大易宝(EZPod)正式面向全国发售。每套售价458元。 <br/><br/> 盛大易宝是针对终端消费者推出的包含EZCenter宽带娱乐门户软件在内的电脑宽带娱乐中心。盛大董事长兼CEO陈天桥表示:“盛大推出的EZ系列产品中,掌上网络娱乐终端EZMini已经发布。此次基于PC平台的EZ Pod正式发售,将为定位于电视与宽带平台的‘宽带娱乐电脑’EZStation的上市做好市场预热,奠定用户基础。” <br/><br/> 目前,英特尔已与盛大签约,将在明年包销50万套盛大易宝。<br/> ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> 手机实名制计划年底实施??吃饱了撑的? </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/41.html </link> <pubDate> Fri, 02 Dec 2005 13:35:16 +0800 </pubDate> <guid> http://www.uiokyu.com/post/41.html </guid> <description> <![CDATA[ 手机实名制计划年底实施??吃饱了撑的? 国家信息产业部正在起草一部《通信管理办法》,其中有一个非常敏感的条款,那就是手机用户将实行实名登记制度。信息产业部电信研究院交流中心主任陈育平11月30日表示,手机实名制将于年底左右开始实施,近两亿手机用户计划在2006年内全部完成注册、登记。 ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> 关于cms登陆的一些构想 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/40.html </link> <pubDate> Fri, 02 Dec 2005 10:33:58 +0800 </pubDate> <guid> http://www.uiokyu.com/post/40.html </guid> <description> <![CDATA[ƒ。客户端只需要携带密码。不需要什么钥匙盘的。 <br/>2。服务器不储存密码,而只储存公匙和加密了的私匙。 <br/>3。服务器能验证用户是否拥有密码原文,客户端没有密码原文则无法进行欺骗。(不需要保证传输中的数据包的安全,随便看) <br/>4。服务器无法欺骗用户的密码。即使服务器是恶意的。 <br/>5。客户端无法进行暴力破解。 <br/>6。生成临时的密匙用于加密以后的传输的数据。服务器和客户端的密匙是不同的。这个临时的密匙在初始化的时候也是安全的。 <br/>7。服务器储存的数据是针对用户加密的。 <br/>8。用户能用其他用户的身份对数据进行加密,加密后的数据只有接收者才能看。发送者也无法阅读。 ]]> </description> <category> Doc </category> </item> <item> <title> 基于密码的安全 的一些想法 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/39.html </link> <pubDate> Fri, 02 Dec 2005 10:30:37 +0800 </pubDate> <guid> http://www.uiokyu.com/post/39.html </guid> <description> <![CDATA[ 安全设计的一个准则就是:除了你,没有人可以冒充你。<br/>什么意思呢?就是一个安全的系统中,即使是管理员也无法知道别人的密码,甚至是系统的设计者也不能冒充别人进入,或许你是管理员,你可以任意修改别人的密码,但是由于修改密码的操作是会被记录在案的,因此你仍然无法做到神不知鬼不觉地冒充别人做 ]]> </description> <category> Doc </category> </item> <item> <title> 设计,看上去很美 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/38.html </link> <pubDate> Fri, 02 Dec 2005 10:23:34 +0800 </pubDate> <guid> http://www.uiokyu.com/post/38.html </guid> <description> <![CDATA[ 设计,看上去很美 <br/> 设计没有标准,模式充满变化,我们对设计与模式的探讨,就是希望能从没有标准的设计中体验设计的乐趣,从充满变化的模式中寻求问题的解决之道。<br/> 我这里所谓“设计没有标准”,其实并非没有标准,现实是设计的标准实在太多了。我们都希望找到最好的设计方案,然而什么是最好,每个人都有自己的“哈姆雷特”。满足客户需求的设计就是最好的,这个结论我想不会有人反对,前提是,怎样通过设计来满足 ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> 体验微软的在线百科全书——MSN机器人 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/37.html </link> <pubDate> Fri, 02 Dec 2005 10:05:47 +0800 </pubDate> <guid> http://www.uiokyu.com/post/37.html </guid> <description> <![CDATA[ 比较强,可以解方程,问一些问题。在MSN里面把[email protected]加为好友,然后和他聊天就可以了。 ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> 最小巧的播放器.常用功能齐全哦.. </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/36.html </link> <pubDate> Thu, 01 Dec 2005 13:31:56 +0800 </pubDate> <guid> http://www.uiokyu.com/post/36.html </guid> <description> <![CDATA[ 最小巧的播放器.常用功能齐全哦..<br/>http://www.uiokyu.com/upload/CHKenPlayer.rar<br/> ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> wow 主题曲 摇头版... 不相信你不晕 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/35.html </link> <pubDate> Thu, 01 Dec 2005 11:30:58 +0800 </pubDate> <guid> http://www.uiokyu.com/post/35.html </guid> <description> <![CDATA[ wow主体曲. 开着两个喇叭的人坐在喇叭的中央位置..<br/><br/>然后播放..戴耳机者效果更佳.音量不要太小.以能清楚听清为上 .能听完不吐者. 厉害啊... ]]> </description> <category> Personal </category> </item> <item> <title> Dream Catcher-Bandari 一个人的歌.追梦而已. </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/34.html </link> <pubDate> Thu, 01 Dec 2005 10:51:03 +0800 </pubDate> <guid> http://www.uiokyu.com/post/34.html </guid> <description> <![CDATA[ 今天在办公室里听到一首歌.非常好听..也非常适合一个人的时候听听.<br/><br/><br/><br/>--------------------------------------------------------------------------------<br/><br/><br/> http://xiuer.net/music/dreamcatcher.mp3<br/> ]]> </description> <category> Personal </category> </item> <item> <title> 苹果多媒体中心 iMac Short </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/33.html </link> <pubDate> Thu, 01 Dec 2005 09:21:48 +0800 </pubDate> <guid> http://www.uiokyu.com/post/33.html </guid> <description> <![CDATA[ 苹果多媒体中心 iMac Short <br/>想知道完全没有底座是多么的酷,我们来看iMac Short.<br/>16:10的大TFT屏幕,抛弃了传统的极其不合理的16:9设计,采用全新的主扳设计,厚度比原先减小30%。重新设计的 romote,采用点触旋转式按钮盘。 ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> 葡萄美酒夜光杯 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/32.html </link> <pubDate> Wed, 30 Nov 2005 15:42:14 +0800 </pubDate> <guid> http://www.uiokyu.com/post/32.html </guid> <description> <![CDATA[ 葡萄美酒夜光杯 ]]> </description> <category> Personal </category> </item> <item> <title> 凤芯2号即将发布? </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/31.html </link> <pubDate> Wed, 30 Nov 2005 13:23:55 +0800 </pubDate> <guid> http://www.uiokyu.com/post/31.html </guid> <description> <![CDATA[ 新浪科技讯 11月29日,来自中科院计算所的消息,我国自主研发的凤芯2号芯片将于12月1日对外发布,该芯片基于AVS标准,同时支持最新的H.264技术。<br/>  凤芯2号相关负责人向新浪科技透露,凤芯2号采用了自主研究的多标准可配置数字视音频编解码技术,实现了很高的芯片复用度,芯片面积可节省30%以上,较国外同类产品具有很强的竞争力。<br/> ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> 单字母域名明年开卖? </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/30.html </link> <pubDate> Wed, 30 Nov 2005 11:57:42 +0800 </pubDate> <guid> http://www.uiokyu.com/post/30.html </guid> <description> <![CDATA[ 为了避免重名,现在的.com域名越来越长也越来越复杂,而诸如“a.com”,“b.com”等单字母域名目前仍未开始使用。而ABCNews报道,负责域名管理的ICANN目前正考虑放松对单字母域名的使用限制。 ]]> </description> <category> News &amp; amp;Copied </category> </item> <item> <title> Ping 环回地址 </title> <author> [email protected] (admin) </author> <link> http://www.uiokyu.com/post/29.html </link> <pubDate> Tue, 29 Nov 2005 19:11:42 +0800 </pubDate> <guid> http://www.uiokyu.com/post/29.html </guid> <description> <![CDATA[ 使用 PING 命令验证 TCP/IP 是否正常工作。为此,请在命令提示符处键入以下命令来 Ping 环回地址 (127.0.0.1): <br/>ping 127.0.0.1<br/><br/>您应该收到类似下面的响应: <br/>Pinging 127.0.0.1 with 32 bytes of data:<br/><br/>Reply from 127.0.0.1:bytes=32 time=<10ms ]]> </description> <category> Doc </category> </item> </channel> </rss>
   提示:您可以先修改部分代码再运行

想在同一个html中调用以上信息. (不用<iframe>)

作者: uiokyu   发布时间: 2005-12-07


var xml = new ActiveXObject("Microsoft.XMLDOM") xml.async = false xml.load("http://bbs.sept5.com/rssfeed.asp?rssid=4&boardid=8")// Load XML var xml2 = new ActiveXObject("Microsoft.XMLDOM") xml2.async = false xml2.load("http://bbs.sept5.com/rssfeed.asp?rssid=4&boardid=8")// Load XML
   提示:您可以先修改部分代码再运行

作者: selo   发布时间: 2005-12-07

这样调用? js吗? 能完整调用上面的两个xml吗?

作者: uiokyu   发布时间: 2005-12-08

是js,你喜欢调几个就几个,你可以每个<div>一个xml,也可以用其它标签。

作者: selo   发布时间: 2005-12-15