<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>正则表达式 &#8211; LPC影子技术分享</title>
	<atom:link href="https://www.mudbest.com/tag/%E6%AD%A3%E5%88%99%E8%A1%A8%E8%BE%BE%E5%BC%8F/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.mudbest.com</link>
	<description>行影不离,忘之却步.</description>
	<lastBuildDate>Tue, 03 Jul 2012 07:39:12 +0000</lastBuildDate>
	<language>zh-Hans</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.1</generator>
	<item>
		<title>正则表达式 \w \s \d \b</title>
		<link>https://www.mudbest.com/%e6%ad%a3%e5%88%99%e8%a1%a8%e8%be%be%e5%bc%8f-w-s-d-b/</link>
		
		<dc:creator><![CDATA[hkshadow]]></dc:creator>
		<pubDate>Tue, 03 Jul 2012 07:39:03 +0000</pubDate>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[正则表达式]]></category>
		<guid isPermaLink="false">http://www.mudbest.com/?p=1127</guid>

					<description><![CDATA[. 匹配除换行符以外的任意字符 \w 匹配字母或数字或下划线或汉字 等价于 &#8216;[^A-Za-z0- ... <a title="正则表达式 \w \s \d \b" class="read-more" href="https://www.mudbest.com/%e6%ad%a3%e5%88%99%e8%a1%a8%e8%be%be%e5%bc%8f-w-s-d-b/" aria-label="阅读 正则表达式 \w \s \d \b">阅读更多</a>]]></description>
										<content:encoded><![CDATA[<p>. 匹配除换行符以外的任意字符<br />
\w 匹配字母或数字或下划线或汉字 等价于 &#8216;[^A-Za-z0-9_]&#8217;。<br />
\s 匹配任意的空白符<br />
\d 匹配数字<br />
\b 匹配单词的开始或结束<br />
^ 匹配字符串的开始<br />
$ 匹配字符串的结束<br />
<span id="more-1127"></span><br />
\w能不能匹配汉字要视你的操作系统和你的应用环境而定</p>
<p>\w 任意一个字母或数字或下划线，也就是 A～Z,a～z,0～9,_ 中任意一个<br />
一般来说，是这样的，但是在某些情况下，\w也会匹配本地字符集，比如中文系统的中文，全角数字等，所以在明确要求是A～Z,a～z,0～9,_ 中的一个的时候，用[A-Za-z0-9_]，而不用\w</p>
<p>判定条件我知道的有两个，两个条件是互相制约的：<br />
一是要看你的系统是什么系统，中文系统下是可以匹配汉字的<br />
二是要看你的应用环境，如果是在C#程序中，是可以匹配汉字的，在javascript或验证控件中，是不可以匹配汉字的</p>
<p>其它\d，\s也是如此</p>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
