新书推介:《语义网技术体系》
作者:瞿裕忠,胡伟,程龚
   XML论坛     W3CHINA.ORG讨论区     计算机科学论坛     SOAChina论坛     Blog     开放翻译计划     新浪微博  
 
  • 首页
  • 登录
  • 注册
  • 软件下载
  • 资料下载
  • 核心成员
  • 帮助
  •   Add to Google

    >> 本版讨论DOM, SAX, XPath等。
    [返回] 中文XML论坛 - 专业的XML技术讨论区XML.ORG.CN讨论区 - XML技术『 DOM/SAX/XPath 』 → [求助]怎样实现这个xml文件的操作 查看新帖用户列表

      发表一个新主题  发表一个新投票  回复主题  (订阅本版) 您是本帖的第 5448 个阅读者浏览上一篇主题  刷新本主题   树形显示贴子 浏览下一篇主题
     * 贴子主题: [求助]怎样实现这个xml文件的操作 举报  打印  推荐  IE收藏夹 
       本主题类别:     
     fz-l 帅哥哟,离线,有人找我吗?
      
      
      等级:大一新生
      文章:1
      积分:53
      门派:XML.ORG.CN
      注册:2008/7/25

    姓名:(无权查看)
    城市:(无权查看)
    院校:(无权查看)
    给fz-l发送一个短消息 把fz-l加入好友 查看fz-l的个人资料 搜索fz-l在『 DOM/SAX/XPath 』的所有贴子 引用回复这个贴子 回复这个贴子 查看fz-l的博客楼主
    发贴心情 [求助]怎样实现这个xml文件的操作

    a.txt 文件 为我从实际文件中提取的一部分内容
    b.txt文件 为我想实现的结果

    a.txt内容如下:

    <?xml version ="1.0"?>
    <configuration xmlns="urn:microsoft-catalog:XML_Metabase_V64_0">
    <MBProperty>
    <IIS_Global Location ="."
      BINSchemaTimeStamp="251a765c4d99c801"
      ChangeNumber="32763"
      HistoryMajorVersionNumber="287"
      

    SessionKey="49634b62980000004c00000040000000010200000168000000a40000562eac418683ad5dbacdcc0d5597e0a196c4f05c2179a088555682bd980277c5eb1d7c9f4549930d09dd3f466

    a63942bc764e88a8ee577f36571d23de94d239effff4e005a3f7fc4d3657f011ae03ac72b2f03416fbe9bff88920d14a4bb87df4c69f1369c9408767988169fdc5a8ce267ee56b80dd96c8338ed52

    cc326cd8e7dd7ec59c"
      XMLSchemaTimeStamp="7f7c785c4d99c801"
     >
    </IIS_Global>

    ~~~~~~~~~~~~~~~~~~站点test1.com~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    <IIsWebServer Location ="/LM/W3SVC/1692685952"
      AuthFlags="0"
      ServerAutoStart="TRUE"
      ServerBindings=":80:test1.com"
      ServerComment="test1.com"
     >
    </IIsWebServer>
    <IIsFilters Location ="/LM/W3SVC/1692685952/filters"
      

    AdminACL="49634462f0000000a400000040000000c18618ef8781fc29d0feeb5cc6685376b01fc41fe08d8245f4f702bfbd9f7ae1f74429e9e507f6f5729ef4a3e634126cb486569210f10310c4c

    a0b701d02120f72f3a72e5339c7a367273ce8b4fdc590417c3457c795c314f6ff9669ad8de29f6957debdf4551e7f01a5a000972deea05104d5c284b1e47d057d04fd8de14c8e817460be132da8d7

    674a6b10dd788033c8347c98faa64c9fdf844fa581210c615790dc15e48328f89b00f269c098ace7ccebaa144d961451ca649afa782301085ffc374c71c4205fa8f1420f673bf7ce4eae3a16758a7

    f1db3ea1cc322266185ed75916cce3d9112"
     >
    </IIsFilters>
    <IIsWebVirtualDir Location ="/LM/W3SVC/1692685952/root"
      AccessFlags="AccessRead"
      AppFriendlyName="默认应用程序"
      AppIsolated="2"
      AppPoolId="AppPool #10"
      AppRoot="/LM/W3SVC/1692685952/Root"
      AuthFlags="AuthAnonymous | AuthNTLM"
      DirBrowseFlags="DirBrowseShowDate | DirBrowseShowTime | DirBrowseShowSize | DirBrowseShowExtension | DirBrowseShowLongDate |

    EnableDefaultDoc"
      Path="F:\perl"
      

    UNCPassword="49634462500000000600000040000000c18618ef86813600e050d39feb134cf3024228de33bd68f2be421a4acacb679900d66487abbb6bf4023b221cb811d48ca890d75d9a5d26fa

    271b0d2978ed22733177004f7d762e76"
     >
    </IIsWebVirtualDir>

    ~~~~~~~~~~~~~~~~~~站点test2.com~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    <IIsWebServer Location ="/LM/W3SVC/1796746353"
      AuthFlags="0"
      ServerAutoStart="TRUE"
      ServerBindings=":80:test2.com"
      ServerComment="test2.com"
     >
    </IIsWebServer>
    <IIsFilters Location ="/LM/W3SVC/1796746353/filters"
      

    AdminACL="49634462f0000000a400000040000000c18618ef8781fc29d0feeb5cc6685376b01fc41fe08d8245f4f702bfbd9f7ae1f74429e9e507f6f5729ef4a3e634126cb486569210f10310c4c

    a0b701d02120f72f3a72e5339c7a367273ce8b4fdc590417c3457c795c314f6ff9669ad8de29f6957debdf4551e7f01a5a000972deea05104d5c284b1e47d057d04fd8de14c8e817460be132da8d7

    674a6b10dd788033c8347c98faa64c9fdf844fa581210c615790dc15e48328f89b00f269c098ace7ccebaa144d961451ca649afa782301085ffc374c71c4205fa8f1420f673bf7ce4eae3a16758a7

    f1db3ea1cc322266185ed75916cce3d9112"
     >
    </IIsFilters>
    <IIsWebVirtualDir Location ="/LM/W3SVC/1796746353/root"
      AccessFlags="AccessRead"
      AppFriendlyName="默认应用程序"
      AppIsolated="2"
      AppPoolId="AppPool #10"
      AppRoot="/LM/W3SVC/1796746353/Root"
      AuthFlags="AuthAnonymous | AuthNTLM"
      DirBrowseFlags="DirBrowseShowDate | DirBrowseShowTime | DirBrowseShowSize | DirBrowseShowExtension | DirBrowseShowLongDate |

    EnableDefaultDoc"
      Path="E:\dbbackup"
      

    UNCPassword="49634462500000000600000040000000c18618ef86813600e050d39feb134cf3024228de33bd68f2be421a4acacb679900d66487abbb6bf4023b221cb811d48ca890d75d9a5d26fa

    271b0d2978ed22733177004f7d762e76"
     >
    </IIsWebVirtualDir>


    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~进程池AppPool #10~~~~~~~~~~~~~~~~~

    <IIsApplicationPool Location ="/LM/W3SVC/AppPools/AppPool #10"
      AppPoolAutoStart="TRUE"
     >
    </IIsApplicationPool>

    b.txt内容如下:

    <?xml version ="1.0"?>
    <configuration xmlns="urn:microsoft-catalog:XML_Metabase_V64_0">
    <MBProperty>
    <IIS_Global Location ="."
      BINSchemaTimeStamp="251a765c4d99c801"
      ChangeNumber="32763"
      HistoryMajorVersionNumber="287"
      

    SessionKey="49634b62980000004c00000040000000010200000168000000a40000562eac418683ad5dbacdcc0d5597e0a196c4f05c2179a088555682bd980277c5eb1d7c9f4549930d09dd3f466

    a63942bc764e88a8ee577f36571d23de94d239effff4e005a3f7fc4d3657f011ae03ac72b2f03416fbe9bff88920d14a4bb87df4c69f1369c9408767988169fdc5a8ce267ee56b80dd96c8338ed52

    cc326cd8e7dd7ec59c"
      XMLSchemaTimeStamp="7f7c785c4d99c801"
     >
    </IIS_Global>

    <IIsWebServer Location ="/LM/W3SVC/1692685952"
      AuthFlags="0"
      ServerAutoStart="TRUE"
      ServerBindings=":80:test1.com"
      ServerComment="test1.com"
     >
    </IIsWebServer>
    <IIsFilters Location ="/LM/W3SVC/1692685952/filters"
      

    AdminACL="49634462f0000000a400000040000000c18618ef8781fc29d0feeb5cc6685376b01fc41fe08d8245f4f702bfbd9f7ae1f74429e9e507f6f5729ef4a3e634126cb486569210f10310c4c

    a0b701d02120f72f3a72e5339c7a367273ce8b4fdc590417c3457c795c314f6ff9669ad8de29f6957debdf4551e7f01a5a000972deea05104d5c284b1e47d057d04fd8de14c8e817460be132da8d7

    674a6b10dd788033c8347c98faa64c9fdf844fa581210c615790dc15e48328f89b00f269c098ace7ccebaa144d961451ca649afa782301085ffc374c71c4205fa8f1420f673bf7ce4eae3a16758a7

    f1db3ea1cc322266185ed75916cce3d9112"
     >
    </IIsFilters>
    <IIsWebVirtualDir Location ="/LM/W3SVC/1692685952/root"
      AccessFlags="AccessRead"
      AppFriendlyName="默认应用程序"
      AppIsolated="2"
      AppPoolId="test1.com #10"
      AppRoot="/LM/W3SVC/1692685952/Root"
      AuthFlags="AuthAnonymous | AuthNTLM"
      DirBrowseFlags="DirBrowseShowDate | DirBrowseShowTime | DirBrowseShowSize | DirBrowseShowExtension | DirBrowseShowLongDate |

    EnableDefaultDoc"
      Path="F:\perl"
      

    UNCPassword="49634462500000000600000040000000c18618ef86813600e050d39feb134cf3024228de33bd68f2be421a4acacb679900d66487abbb6bf4023b221cb811d48ca890d75d9a5d26fa

    271b0d2978ed22733177004f7d762e76"
     >
    </IIsWebVirtualDir>


    <IIsWebServer Location ="/LM/W3SVC/1796746353"
      AuthFlags="0"
      ServerAutoStart="TRUE"
      ServerBindings=":80:test2.com"
      ServerComment="test2.com"
     >
    </IIsWebServer>
    <IIsFilters Location ="/LM/W3SVC/1796746353/filters"
      

    AdminACL="49634462f0000000a400000040000000c18618ef8781fc29d0feeb5cc6685376b01fc41fe08d8245f4f702bfbd9f7ae1f74429e9e507f6f5729ef4a3e634126cb486569210f10310c4c

    a0b701d02120f72f3a72e5339c7a367273ce8b4fdc590417c3457c795c314f6ff9669ad8de29f6957debdf4551e7f01a5a000972deea05104d5c284b1e47d057d04fd8de14c8e817460be132da8d7

    674a6b10dd788033c8347c98faa64c9fdf844fa581210c615790dc15e48328f89b00f269c098ace7ccebaa144d961451ca649afa782301085ffc374c71c4205fa8f1420f673bf7ce4eae3a16758a7

    f1db3ea1cc322266185ed75916cce3d9112"
     >
    </IIsFilters>
    <IIsWebVirtualDir Location ="/LM/W3SVC/1796746353/root"
      AccessFlags="AccessRead"
      AppFriendlyName="默认应用程序"
      AppIsolated="2"
      AppPoolId="test1.com #10"
      AppRoot="/LM/W3SVC/1796746353/Root"
      AuthFlags="AuthAnonymous | AuthNTLM"
      DirBrowseFlags="DirBrowseShowDate | DirBrowseShowTime | DirBrowseShowSize | DirBrowseShowExtension | DirBrowseShowLongDate |

    EnableDefaultDoc"
      Path="E:\dbbackup"
      

    UNCPassword="49634462500000000600000040000000c18618ef86813600e050d39feb134cf3024228de33bd68f2be421a4acacb679900d66487abbb6bf4023b221cb811d48ca890d75d9a5d26fa

    271b0d2978ed22733177004f7d762e76"
     >
    </IIsWebVirtualDir>


    <IIsApplicationPool Location ="/LM/W3SVC/AppPools/test1.com #10"
      AppPoolAutoStart="TRUE"
     >
    </IIsApplicationPool>
    <IIsApplicationPool Location ="/LM/W3SVC/AppPools/test2.com #10"
      AppPoolAutoStart="TRUE"
     >
    </IIsApplicationPool>


    上面的内容只是提取的一少部分,所以和实际运用会有点差别。a.txt中的2个站点有相同的特征都是同属AppPool #10。所以需要提取出来建对应的进程池 test1.com #10和test2.com #10,最后修改原来的AppPoolId中的 AppPool #10 为 test1.com #10和test2.com #10


       收藏   分享  
    顶(0)
      




    点击查看用户来源及管理<br>发贴IP:*.*.*.* 2008/7/25 9:54:00
     
     GoogleAdSense
      
      
      等级:大一新生
      文章:1
      积分:50
      门派:无门无派
      院校:未填写
      注册:2007-01-01
    给Google AdSense发送一个短消息 把Google AdSense加入好友 查看Google AdSense的个人资料 搜索Google AdSense在『 DOM/SAX/XPath 』的所有贴子 访问Google AdSense的主页 引用回复这个贴子 回复这个贴子 查看Google AdSense的博客广告
    2024/11/8 13:02:45

    本主题贴数1,分页: [1]

    管理选项修改tag | 锁定 | 解锁 | 提升 | 删除 | 移动 | 固顶 | 总固顶 | 奖励 | 惩罚 | 发布公告
    W3C Contributing Supporter! W 3 C h i n a ( since 2003 ) 旗 下 站 点
    苏ICP备05006046号《全国人大常委会关于维护互联网安全的决定》《计算机信息网络国际联网安全保护管理办法》
    62.500ms