XML的SelectNodes使用方法以及XPath

XPath 是 XML 的内容,这里 SelectNodes 是 C# 中 XmlDocument 或 XmlNode 的一个方法。SelectNodes 使用 XPath 来选取节点

fckeditor漏洞大全

0.强制建立1.asp

/fckeditor/editor/filemanager/connectors/aspx/connector.aspx?Command=CreateFolder&Type=Image&CurrentFolder=/1.asp&NewFolderName=Test%20Folder

1、查看编辑器版本:

/fckeditor/editor/dialog/fck_about.html /FCKeditor/_whatsnew.html 

...

windows 2003 用forfiles删除过期文件

Forfiles

从文件夹或树中选择要进行批处理的文件。

语法

forfiles [/p Path] [/m SearchMask] [/s] [/c Command] [/d[{+ | -}] [{MM/DD/YYYY | DD}]]

...

查看SQL Server事务日志的方法

在SQL Server 7.0和SQL Server2000中,可以用下面的命令查看:

实用倒车技巧

xmlpath基本语法

节点的关系:
父(Parent)
子(Children)
同胞(Sibling)
先辈(Ancestor)
后代(Descendant)

路径表达式

nodename 选取此节点的所有子节点
/ 从根节点选取
// 从匹配选择的当前节点选择文档中的节点,而不考虑它们的位置
. 选取当前节点
.. 选取当前节点的父节点
@    选取属性

谓语(Predicates)
谓语被嵌在方括号中。
/bookstore/book[1]
/bookstore/book[last()]
/bookstore/book[price<10]
        通配符

*         匹配任何元素节点
    @*      匹配任何属性节点
    node() 匹配任何类型的节点

XPath 轴

ancestor 选取当前节点的所有先辈(父、祖父等) 
ancestor-or-self 选取当前节点的所有先辈(父、祖父等)以及当前节点本身
attribute 选取当前节点的所有属性
child 选取当前节点的所有子元素。
descendant 选取当前节点的所有后代元素(子、孙等)。
descendant-or-self 选取当前节点的所有后代元素(子、孙等)以及当前节点本身。
following 选取文档中当前节点的结束标签之后的所有节点。
namespace 选取当前节点的所有命名空间节点
parent 选取当前节点的父节点。
preceding 选取文档中当前节点的开始标签之前的所有节点。
preceding-sibling 选取当前节点之前的所有同级节点。
self 选取当前节点。

使用Xpath对XML进行模糊查询

如果要对XML文件进行模糊查找的话是一个比较麻烦的事情,Xpath表达式中没有像文件系统中的“*”或"?" 或者有像SQL表达式中的"%",这样的模糊查找的通配符。但是还好,在Xpath的函数中提供了像contains和match这样的函数。

面向网站管理员的Web缓存加速指南[翻译]

这是一篇知识性的文档,主要目的是为了让Web缓存相关概念更容易被开发者理解并应用于实际的应用环境中。为了简要起见,某些实现方面的细节被简化或省略了。如果你更关心细节实现则完全不必耐心看完本文,后面参考文档和更多深入阅读部分可能是你更需要的内容。

js取得某一范围的随机数

function getRandom(min,max){
            return Math.floor(min+Math.random()*(max-min));
        }   

XMLHTTP 与 ServerXMLHTTP的区别

XMLHTTP vs ServerXMLHTTP

 

XMLHTTP

ServerXMLHTTP

1

Works on Windows 98, 95 and ME

Requires at least Windows NT 4 with IE5.01 .

2

 

Does not have a means of waiting for an async call other than using another thread to handle the response via onreadystatechange.

 

Another technique is to loop on the main thread, polling the readystate property.

For example:

 While xmlhttp.readystate <> 4

   ' async request not complete yet; still waiting

 Wend

 

But this is not as efficient as the ServerXMLHTTP's WaitForResponse method

Has a waitForResponse method with a timeout when using async calls.

3

 

Allows configuring timeouts when sending messages.

4

Is designed for single-user, desktop applications, such as running in a browser-based app.

 

XMLHTTP's assumption that it is used only in single-user environments has security implications.

Do not use XMLHTTP in multi-user scenarios such as on IIS/ASP servers.

Also, in various cases, XMLHTTP may display UI dialogs (to collect credentials).

Supports multi-user, server-based applications, such as ASP apps.

5

Because XMLHTTP is designed for single-user client applications and is based on WinInet, it enforces strict limits on the number of simultaneous connections to a given server.

The limit is either 2 or 4 (depending on HTTP version).

The ServerXMLHTTP component does not impose any limits on the number of connections to a server.

6

XMLHTTP integrates with the IE browser's cache, which may cause problems in which "stale" response data is returned.

ServerXMLHTTP does not implement a cache.

7

XMLHTTP is HTTP/1.1 compliant.

XMLHTTP does support HTTP/1.1 chunking.

ServerXMLHTTP reports itself as an HTTP/1.0 client.

The reason is that ServerXMLHTTP does not support the HTTP/1.1 response "chunking" feature, which is required for 1.1 compliance.

8

By using the IE browser's proxy settings, XMLHTTP can take advantage of IE's auto-detection of proxy servers.

If IE is configured to access sites via a proxy server, then all requests made via XMLHTTP will also go through the proxy.

However, IE (and thus XMLHTTP) can be configured to bypass the proxy server for certain sites (assuming that a direct connection to the target server can be made).

This is done in the "Tools/Internet Options/Connections/LAN Settings" dialog in IE.

The "Bypass proxy server for local addresses" option should be checked to have the proxy server bypassed for intranet sites.

ServerXMLHTTP does not support any auto-detection or discovery of proxy servers; you must explicitly specify the name of the proxy server using the proxycfg.exe utility.

Can be configured with WinHTTP proxy config to access other machines directly (no proxy server).

9

The XMLHTTP component in MSXML 3.0 supports automatic gzip decompression;

ServerXMLHTTP does not.

10

 

ServerXMLHTTP in MSXML 3.0 SP1 supports SSL certificates.

11

重用Socket端口,或者有Socket端口缓存.

没有缓存,每次连接都会启用一个新的Socket端口.

12

 

默认的CodePageUTF8.

默认时,URL被先转换为UTF8编码.

分页:[«]1[2][»]