XML在IE5.0下不能看的问题

bluecc 2003-05-06 11:16:08
我用CSDN的树,在IE6.0下可以看,在IE5.0下不能看。以下是原码
1。deeptree.htm
<html>
<head>
<META NAME="Robots" CONTENT="noindex">
<title>导航条</title>
<link rel="stylesheet" type="text/css" href="deeptree.css">
<base target="main">
</head>

<body topmargin="0" leftmargin="0" marginheight="0" marginwidth="0" bgcolor="#e4f2fc" text="#000000">

<nobr>
<div id="deeptree" class="deeptree" CfgXMLSrc="deeptreeconfig.xml">
</div>
</nobr>

</body>
</html>

<body topmargin="0" leftmargin="0" marginheight="0" marginwidth="0" bgcolor="#e4f2fc" text="#000000">

2.deeptreeconfig.xml
<deeptreeconfig>
<TopXMLSrc>top.xml</TopXMLSrc>
<TreeLabel>Welcome to the MSDN Library</TreeLabel>
<StartPage>/nhp/default.asp?contentid=28000546</StartPage>
<ErrorPage>http://www.microsoft.com</ErrorPage>
<ContentTarget>fraContent</ContentTarget>
<TreeId>FunctionTree</TreeId>
<TreeRootPath>/library/default.asp</TreeRootPath>
<Locale>en-us</Locale>
<LocaleTextDirection>LTR</LocaleTextDirection>
</deeptreeconfig>

3.top.xml
<Tree TreeId="FunctionTree" NodeXmlSrc="top.xml">
<TreeNode NodeId="FunctionTree2" Title="工程信息" NodeXmlSrc="information.xml">
</TreeNode>
<TreeNode NodeId="FunctionTree3" Title="文档管理" NodeXmlSrc="documents.xml">
</TreeNode>
<TreeNode NodeId="FunctionTree4" Title="工程进度" NodeXmlSrc="progress.xml">
</TreeNode>
<TreeNode NodeId="FunctionTree5" Title="合同管理" NodeXmlSrc="pact.xml">
</TreeNode>
</Tree>

4.information.xml
锘?TreeNode NodeId="msdnlib3" Title="宸ョ▼淇℃伅" ParentXmlSrc="/library/en-us/toc/msdnlib/top.xml" NodeXmlSrc="/library/en-us/toc/msdnlib/msdnlib3_.xml">
<TreeNode NodeId="Information1" Title="宸ョ▼姒傚喌" Target="main" Href="../projectsurvey/survey.htm" />
<TreeNode NodeId="Information2" Title="鏍囨鍒掑垎鍥? Target="main" Href="../projectsurvey/picture.htm" />
<TreeNode NodeId="Information3" Title="鏍囨鍒掑垎琛? Target="main" Href="../projectsurvey/table.asp" />
<TreeNode NodeId="Information4" Title="杞︾珯鍥? Target="main"
Href="../projectsurvey/pic.asp?str=tbl" />
<TreeNode NodeId="Information5" Title="閫氳褰? Target="main"
Href="../projectsurvey/addresslist.asp" />
<TreeNode NodeId="Information6" Title="璧勬枡娓呭崟" Target="main" Href="../documents/showdatazlqd.asp?strShowChildName=All" />
<TreeNode NodeId="Information7" Title="瑙勭珷鍒跺害" Target="main" Href="../projectsurvey/showdataGZZD.asp?strShowChildName=All" />
</TreeNode>

文件4出现乱码也不知为何
...全文
24 9 打赏 收藏 转发到动态 举报
写回复
用AI写文章
9 条回复
切换为时间正序
请发表友善的回复…
发表回复
bluecc 2003-05-13
  • 打赏
  • 举报
回复
好的,再试试,结贴
bluecc 2003-05-09
  • 打赏
  • 举报
回复
问题解决了,不过好象是由于在2000下用记事本编辑的,在98下打开有中文的部分成了乱码,在98下删除乱码后,就可以了.其间用了net_lover(孟子E章)的方法,好象还是不行,存了之后在98下还是有乱码.不知道是什么原因.难道2000和98的记事本还有问题,那么到底应该用哪个呢
assa 2003-05-09
  • 打赏
  • 举报
回复
推荐用XMLwriter2
下载地址 http://xmlwriter.net/
很好用的:)
assa 2003-05-09
  • 打赏
  • 举报
回复
5。0在解析xml有一些问题,除了要注意中文问题外,还要注意xsl
jchmax 2003-05-09
  • 打赏
  • 举报
回复
<?xml version='1.0' encoding='gb2312'?>
在碰到乱码的问题是要弄清楚编码指定的是什么,否则无法迅速有效的解决问题
孟子E章 2003-05-06
  • 打赏
  • 举报
回复
information.xml
格式保存为utf-8,win2k记事本可以转换
ssm1226 2003-05-06
  • 打赏
  • 举报
回复
try:

<?xml version='1.0' encoding='gb2312'?>
sunssc 2003-05-06
  • 打赏
  • 举报
回复
加上一行
<?xml version="1.0" encoding="GB2312"?>
是有必要的,


CoolAbu 2003-05-06
  • 打赏
  • 举报
回复
在文件头加上<?xml version="1.0" encoding="GB2312"?>

如下:

<?xml version="1.0" encoding="GB2312"?>
<TreeNode NodeId="msdnlib07">
<Tree TreeId="dnaspnet" NodeXmlSrc="top.xml">
<TreeNode NodeId="dnaspnet2" Href="http://oa.37c.info" Title="一" />
<TreeNode NodeId="dnaspnet3" Href="http://oa.37c.info" Title="二" />
<TreeNode NodeId="dnaspnet4" Href="http://oa.37c.info" Title="三" />
<TreeNode NodeId="dnaspnet5" Href="http://oa.37c.info" Title="四" />
</Tree>
</TreeNode>

8,906

社区成员

发帖
与我相关
我的任务
社区描述
XML/XSL相关问题讨论专区
社区管理员
  • XML/XSL社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧