<?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>Observer Life &#187; HTML/JavaScript</title>
	<atom:link href="http://observerlife.com/category/htmljavascript/feed/" rel="self" type="application/rss+xml" />
	<link>http://observerlife.com</link>
	<description>To be a better man (Observer)</description>
	<lastBuildDate>Sun, 05 Sep 2010 16:21:09 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>HTTP/1.1 Cache-Control header field</title>
		<link>http://observerlife.com/http1-1-cache-control-header-field/</link>
		<comments>http://observerlife.com/http1-1-cache-control-header-field/#comments</comments>
		<pubDate>Thu, 12 Aug 2010 09:52:22 +0000</pubDate>
		<dc:creator>ycg</dc:creator>
				<category><![CDATA[HTML/JavaScript]]></category>
		<category><![CDATA[Cache-Conrol]]></category>
		<category><![CDATA[http]]></category>

		<guid isPermaLink="false">http://observerlife.com/?p=685</guid>
		<description><![CDATA[This standard HTTP header field is defined in RFC 2616 The Cache-Control general-header field is used to specify directives that MUST be obeyed by all caching mechanisms along the request/response chain. The directives specify behavior intended to prevent caches from adversely interfering with the request or response. These directives typically override the default caching algorithms. Cache [...]]]></description>
			<content:encoded><![CDATA[<p><strong>This standard HTTP header field is defined in <a title="Request For Comments #2616" href="http://www.ietf.org/rfc/rfc2616.txt">RFC 2616</a></strong></p>
<p>The Cache-Control general-header field is used to specify directives that MUST be obeyed by all caching mechanisms along the request/response chain. The directives specify behavior intended to prevent caches from adversely interfering with the request or response. These directives typically override the default caching algorithms. Cache directives are unidirectional in that the presence of a directive in a request does not imply that the same directive is to be given in the response.</p>
<p>Cache directives MUST be passed through by a proxy or gateway application, regardless of their significance to that application, since the directives might be applicable to all recipients along the request/response chain. It is not possible to specify a cache-directive for a specific cache.</p>
<h2>Common Cache-Control header values:</h2>
<ul>
<li>Cache-Control: no-cache</li>
<li>Cache-Control: private</li>
<li>Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0</li>
<li>Cache-Control: post-check=0, pre-check=0</li>
<li>Cache-Control: no-store, no-cache, must-revalidate</li>
<li>Cache-Control: must-revalidate, no-store</li>
<li>Cache-Control: no-cache,no-store</li>
<li>Cache-Control: max-age=60</li>
<li>Cache-Control: no-cache, must-revalidate</li>
<li>Cache-Control: no-store</li>
<li>Cache-Control: max-age=0, must-revalidate</li>
<li>Cache-Control: max-age=0, no-cache</li>
<li>Cache-Control: no-cache, no-store, must-revalidate, max-age=0</li>
<li>Cache-Control: no-store, no-cache, must-revalidate, max-age=0</li>
<li>Cache-Control: store, no-cache, must-revalidate</li>
<li>Cache-Control: public</li>
<li>Cache-Control: max-age=86400</li>
<li>Cache-Control: max-age=0</li>
<li>Cache-Control: max-age=2592000</li>
<li>Cache-Control: private, max-age=0</li>
<li>Cache-Control: private, pre-check=0, post-check=0, max-age=0</li>
<li>Cache-Control: max-age=3600</li>
<li>Cache-Control: must-revalidate</li>
<li>Cache-Control: max-age=3600, public</li>
<li>Cache-Control: no-cache, no-store, must-revalidate</li>
<li>Cache-Control: max-age=600</li>
<li>Cache-Control: no-cache=&#8221;set-cookie&#8221;</li>
<li>Cache-Control: private, max-age=0, must-revalidate</li>
<li>Cache-Control: must-revalidate = no-cache</li>
<li>Cache-Control: no-cache, no-store</li>
<li>Cache-Control: private, must-revalidate, max-age=0</li>
<li>Cache-Control: max-age=300</li>
<li>Cache-Control: private, must-revalidate</li>
<li>Cache-Control: Private</li>
<li>Cache-Control: max-age=1</li>
<li>Cache-Control: max-age=604800</li>
<li>Cache-Control: private, no-cache=&#8221;set-cookie&#8221;</li>
<li>Cache-Control: &#8220;must-revalidate&#8221;</li>
<li>Cache-Control: max-age=0, no-store</li>
<li>Cache-Control: no-cache,no-store,must-revalidate</li>
<li>Cache-Control: private, no-cache</li>
<li>Cache-Control: no-cache, pre-check=0, post-check=0</li>
<li>Cache-Control: public, max-age=10800</li>
<li>Cache-Control: max-age=86400, public</li>
<li>Cache-Control: must-revalidate, max-age=1</li>
<li>Cache-Control: no-cache,must-revalidate</li>
<li>Cache-Control: no-store, no-cache</li>
<li>Cache-Control: private, max-age=10800, pre-check=10800</li>
<li>Cache-Control: No-cache</li>
<li>Cache-Control: cache</li>
<li>Cache-Control: max-age=1800</li>
<li>Cache-Control: max-age=345600</li>
<li>Cache-Control: no-cache, must-revalidate, max-age=0</li>
<li>Cache-Control: no-cache, must-revalidate, post-check=0, pre-check=0</li>
<li>Cache-Control: no-cache,no-store,max-age=0</li>
<li>Cache-Control: no-cache=&#8221;set-cookie,set-cookie2&#8243;</li>
<li>Cache-Control: no-store, no-cache, must-revaldate, post-check=1, pre-check=2</li>
<li>Cache-Control: pre-check=0, post-check=0, max-age=0</li>
<li>Cache-Control: private, post-check=0, pre-check=0, max-age=0</li>
<li>Cache-Control: store, no-cache, must-revalidate, post-check=0, pre-check=0</li>
<li>Cache-Control: No-Cache</li>
<li>Cache-Control: max-age=0, no-cache, no-store</li>
<li>Cache-Control: max-age=1209600</li>
<li>Cache-Control: no-cache, no-store, must-revalidate, max-age=-1</li>
<li>Cache-Control: no-cache, private</li>
<li>Cache-Control: no-cache,max-age=0,must-revalidate</li>
<li>Cache-Control: post-check=0, pre-check=0, no-store, no-cache, must-revalidate, post-check=0, pre-check=0</li>
<li>Cache-Control: ,</li>
<li>Cache-Control: max-age=0, private, must-revalidate</li>
<li>Cache-Control: max-age=21600</li>
<li>Cache-Control: max-age=28800</li>
<li>Cache-Control: max-age=5184000</li>
<li>Cache-Control: max-age=82800</li>
<li>Cache-Control: no-cache, max-age=1</li>
<li>Cache-Control: public,max-age=3600</li>
<li>Cache-Control: Public</li>
<li>Cache-Control: max-age=0, private</li>
<li>Cache-Control: max-age=0, private, proxy-revalidate</li>
<li>Cache-Control: max-age=120</li>
<li>Cache-Control: max-age=18000</li>
<li>Cache-Control: max-age=25920000</li>
<li>Cache-Control: max-age=31104000</li>
<li>Cache-Control: max-age=311040000</li>
<li>Cache-Control: max-age=31536000</li>
<li>Cache-Control: max-age=3600, private</li>
<li>Cache-Control: max-age=900</li>
<li>Cache-Control: must-revalidate, no-cache, no-store, private, s-maxage=0, pre-check=0, post-check=0, max-age=0</li>
<li>Cache-Control: no-cache, no-store, must-revalidate</li>
<li>Cache-Control: no-cache, no-store, private</li>
<li>Cache-Control: no-cache,no-transform</li>
<li>Cache-Control: no-cache=&#8221;set-cookie, set-cookie2&#8243;</li>
<li>Cache-Control: no-store, must-revalidate</li>
<li>Cache-Control: no-store, no-cache, must-revalidate, max_age=0</li>
<li>Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0, private</li>
<li>Cache-Control: private, no-cache, max-age=0</li>
<li>Cache-Control: private, no-cache, no-store, proxy-revalidate, no-transform</li>
<li>Cache-Control: private, no-store</li>
<li>Cache-Control: private, proxy-revalidate</li>
<li>Cache-Control: public, max-age=60</li>
<li>Cache-Control: public, max-age=604800, post-check=7200, pre-check=604800</li>
<li>Cache-Control: 7200</li>
<li>Cache-Control: &#8220;no-cache&#8221;</li>
<li>Cache-Control: False</li>
<li>Cache-Control: NO-CACHE</li>
<li>Cache-Control: No-Store</li>
<li>Cache-Control: No-store</li>
<li>Cache-Control: max-age=-111581876</li>
<li>Cache-Control: max-age=-170009618</li>
<li>Cache-Control: max-age=-4366177</li>
<li>Cache-Control: max-age=-492324790</li>
<li>Cache-Control: max-age=-52613456</li>
<li>Cache-Control: max-age=-625447</li>
<li>Cache-Control: max-age=-9274207</li>
<li>Cache-Control: max-age=0, no-cache, no-store, must-revalidate</li>
<li>Cache-Control: max-age=0, no-store, max-age=-2592000</li>
<li>Cache-Control: max-age=0, no-store, no-cache, must-revalidate</li>
<li>Cache-Control: max-age=0, s-maxage=0, private, must-revalidate</li>
<li>Cache-Control: max-age=1, must-revalidate, private</li>
<li>Cache-Control: max-age=1, no-cache, must-revalidate</li>
<li>Cache-Control: max-age=1, s-maxage=1, no-cache, must-revalidate</li>
<li>Cache-Control: max-age=10</li>
<li>Cache-Control: max-age=10800</li>
<li>Cache-Control: max-age=1200</li>
<li>Cache-Control: max-age=124416000</li>
<li>Cache-Control: max-age=14400</li>
<li>Cache-Control: max-age=172800</li>
<li>Cache-Control: max-age=180</li>
<li>Cache-Control: max-age=1800,public</li>
<li>Cache-Control: max-age=25920</li>
<li>Cache-Control: max-age=259200</li>
<li>Cache-Control: max-age=2678400, public</li>
<li>Cache-Control: max-age=300, must-revalidate</li>
<li>Cache-Control: max-age=300, private, proxy-revalidate</li>
<li>Cache-Control: max-age=315360000</li>
<li>Cache-Control: max-age=3600, s-maxage=3600, no-cache</li>
<li>Cache-Control: max-age=43200</li>
<li>Cache-Control: max-age=60, must-revalidate</li>
<li>Cache-Control: max-age=60, private, proxy-revalidate</li>
<li>Cache-Control: max-age=600, must-revalidate</li>
<li>Cache-Control: max-age=600, s-maxage=600</li>
<li>Cache-Control: max-age=604800, public, proxy-revalidate, must-revalidate</li>
<li>Cache-Control: max-age=64800</li>
<li>Cache-Control: max-age=7075</li>
<li>Cache-Control: max-age=7200</li>
<li>Cache-Control: max-age=86400, must-revalidate</li>
<li>Cache-Control: max-age=864000</li>
<li>Cache-Control: must-revalidate, max-age=0</li>
<li>Cache-Control: no &#8211; cache</li>
<li>Cache-Control: no-Cache</li>
<li>Cache-Control: no-cache, max-age=0</li>
<li>Cache-Control: no-cache, max-age=2592000</li>
<li>Cache-Control: no-cache, max-age=3600</li>
<li>Cache-Control: no-cache, max-age=86400</li>
<li>Cache-Control: no-cache, must-revalidate, max_age=0</li>
<li>Cache-Control: no-cache, must-revalidate, max_age=0, private</li>
<li>Cache-Control: no-cache, must-revalidate, no-cache=&#8221;Set-Cookie&#8221;, private</li>
<li>Cache-Control: no-cache, must-revalidate, no-store, post-check=0, pre-check=0</li>
<li>Cache-Control: no-cache, must-revalidate;</li>
<li>Cache-Control: no-cache, no-cache, no-cache, no-cache</li>
<li>Cache-Control: no-cache, no-store, max-age=0, must-revalidate</li>
<li>Cache-Control: no-cache, no-store, max-age=0, private, must-revalidate, proxy-revalidate</li>
<li>Cache-Control: no-cache, no-store, must-revalidate, max-age=0, proxy-revalidate, no-transform, max-age=0</li>
<li>Cache-Control: no-cache, no-store, must-revalidate, private</li>
<li>Cache-Control: no-cache, no-store, no-transform</li>
<li>Cache-Control: no-cache, no-store, private, max-age=0</li>
<li>Cache-Control: no-cache, no-store, private, max-age=1, must-revalidate</li>
<li>Cache-Control: no-cache, no-store, private, must-revalidate, post-check=0, pre-check=0</li>
<li>Cache-Control: no-cache, no-store, proxy-revalidate, must-revalidate</li>
<li>Cache-Control: no-cache, nostore</li>
<li>Cache-Control: no-cache, post-check=0,pre-check=0, max-age=0, max-age=1</li>
<li>Cache-Control: no-cache,must-revalidate, no-store</li>
<li>Cache-Control: no-cache,no-store,max-age=0,s-maxage=0,must-revalidate</li>
<li>Cache-Control: no-cache,private</li>
<li>Cache-Control: no-cache; max-age=0</li>
<li>Cache-Control: no-cache=set-cookie</li>
<li>Cache-Control: no-cash, must-revalidate</li>
<li>Cache-Control: no-store, no-cache, must-revalidate, max-age=0, max-age=0</li>
<li>Cache-Control: no-store, no-cache, private</li>
<li>Cache-Control: no-store,max-age=0,post-check=0,pre-check=0</li>
<li>Cache-Control: no-store,no-cache,must-revalidate, post-check=0, pre-check=0, max_age=0</li>
<li>Cache-Control: no-store,no-cache,must-revalidate,max-age=-1</li>
<li>Cache-Control: no-store,no-cache,must-revalidate,max-age=0,post-check=0,pre-check=0</li>
<li>Cache-Control: no-transform</li>
<li>Cache-Control: post-check=-1, pre-check=-1</li>
<li>Cache-Control: post-check=3600,pre-check=43200</li>
<li>Cache-Control: pre-check=0, post-check=0</li>
<li>Cache-Control: private , proxy-revalidate, must-revalidate</li>
<li>Cache-Control: private, must-revalidate, no-cache, no-check</li>
<li>Cache-Control: private, no-cache, must-revalidate</li>
<li>Cache-Control: private, no-cache, must-revalidate, no-store, max-age=0, post-check=0, pre-check=0</li>
<li>Cache-Control: private, no-cache, no-store, must-revalidate</li>
<li>Cache-Control: private, no-cache, no-store, must-revalidate, max-age=0</li>
<li>Cache-Control: private, no-store, must-revalidate</li>
<li>Cache-Control: private,max-age=3600</li>
<li>Cache-Control: private,no-cache,no-store,max-age=0,must-revalidate,proxy-revalidate</li>
<li>Cache-Control: private,no-cache,no-store,must-revalidate</li>
<li>Cache-Control: proxy-revalidate, max-age=0, must-revalidate</li>
<li>Cache-Control: public, max-age=141456</li>
<li>Cache-Control: public, max-age=294</li>
<li>Cache-Control: public, max-age=30</li>
<li>Cache-Control: public, max-age=300</li>
<li>Cache-Control: public, max-age=5</li>
<li>Cache-Control: public, must-revalidate</li>
<li>Cache-Control: public, must-revalidate, no-cache=&#8221;Set-Cookie&#8221;, max-age=300</li>
<li>Cache-Control: public, proxy-revalidate, must-revalidate, max-age=157680000</li>
<li>Cache-Control: s-maxage=1200, must-revalidate, max-age=0</li>
</ul>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://observerlife.com/ie-firefox-%e6%b5%8f%e8%a7%88%e5%99%a8%e5%88%b7%e6%96%b0%e5%92%8c%e5%bc%ba%e5%88%b6%e5%88%b7%e6%96%b0%e5%8f%91%e9%80%81%e7%9a%84-http-request-header/" rel="bookmark" class="crp_title">IE Firefox 浏览器刷新和强制刷新发送的 HTTP Request Header</a></li><li><a href="http://observerlife.com/cache-control%e6%b6%88%e6%81%af%e5%a4%b4%e5%9f%9f%e8%af%b4%e6%98%8e/" rel="bookmark" class="crp_title">Cache-Control消息头域说明</a></li><li><a href="http://observerlife.com/freebsd-%e8%99%9a%e6%8b%9f%e5%86%85%e5%ad%98%e7%9a%84%e6%b5%85%e6%9e%90/" rel="bookmark" class="crp_title">FreeBSD 虚拟内存的浅析</a></li><li><a href="http://observerlife.com/lighttpdsquidapache%e6%90%ad%e5%bb%ba%e9%ab%98%e6%95%88%e7%8e%87web%e6%9c%8d%e5%8a%a1%e5%99%a8/" rel="bookmark" class="crp_title">Lighttpd+Squid+Apache搭建高效率Web服务器</a></li><li><a href="http://observerlife.com/vi%e4%bd%bf%e7%94%a8%e6%89%8b%e5%86%8c/" rel="bookmark" class="crp_title">VI使用手册</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://observerlife.com/http1-1-cache-control-header-field/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>部分针对手机网站的搜索引擎 robots User-Agent信息</title>
		<link>http://observerlife.com/user-agents-of-some-mobile-robots/</link>
		<comments>http://observerlife.com/user-agents-of-some-mobile-robots/#comments</comments>
		<pubDate>Fri, 06 Aug 2010 03:21:04 +0000</pubDate>
		<dc:creator>ycg</dc:creator>
				<category><![CDATA[HTML/JavaScript]]></category>
		<category><![CDATA[robots]]></category>
		<category><![CDATA[user-agent]]></category>

		<guid isPermaLink="false">http://observerlife.com/?p=679</guid>
		<description><![CDATA[收集并整理了一下部分抓取手机网站的搜索引擎robots的User-Agent信息。有需要的同学可以点击下面的链接下载。 目前比较可恶的是部分国内手机搜索引擎，抓取的时候，不会在User-Agent信息里说明自己是robot。其实，说明一下，这样更方便的。 点击这里下载 Related Posts:Nokia公开机型产品信息csv08-04-2010words to share &#8211; series 3六一儿童节快乐[多图]Google Reader再次更新,添加搜索功能VIM自动化更新脚本推荐:vimana]]></description>
			<content:encoded><![CDATA[<p>收集并整理了一下部分抓取手机网站的搜索引擎robots的User-Agent信息。有需要的同学可以点击下面的链接下载。</p>
<p>目前比较可恶的是部分国内手机搜索引擎，抓取的时候，不会在User-Agent信息里说明自己是robot。其实，说明一下，这样更方便的。</p>
<p><a href="http://observerlife.com/wp-content/uploads/2010/08/robotua.txt" target="_blank">点击这里下载</a></p>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://observerlife.com/nokia_device_info_csv_08-04-2010/" rel="bookmark" class="crp_title">Nokia公开机型产品信息csv08-04-2010</a></li><li><a href="http://observerlife.com/words-to-share-series-3/" rel="bookmark" class="crp_title">words to share &#8211; series 3</a></li><li><a href="http://observerlife.com/%e5%85%ad%e4%b8%80%e5%84%bf%e7%ab%a5%e8%8a%82%e5%bf%ab%e4%b9%90/" rel="bookmark" class="crp_title">六一儿童节快乐</a></li><li><a href="http://observerlife.com/%e5%a4%9a%e5%9b%begoogle-reader%e5%86%8d%e6%ac%a1%e6%9b%b4%e6%96%b0%e6%b7%bb%e5%8a%a0%e6%90%9c%e7%b4%a2%e5%8a%9f%e8%83%bd/" rel="bookmark" class="crp_title">[多图]Google Reader再次更新,添加搜索功能</a></li><li><a href="http://observerlife.com/vimana/" rel="bookmark" class="crp_title">VIM自动化更新脚本推荐:vimana</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://observerlife.com/user-agents-of-some-mobile-robots/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>[share]State of the Mobile Browsers</title>
		<link>http://observerlife.com/sharestate-of-the-mobile-browsers/</link>
		<comments>http://observerlife.com/sharestate-of-the-mobile-browsers/#comments</comments>
		<pubDate>Thu, 29 Jul 2010 02:56:25 +0000</pubDate>
		<dc:creator>ycg</dc:creator>
				<category><![CDATA[HTML/JavaScript]]></category>
		<category><![CDATA[browsers]]></category>
		<category><![CDATA[mobile]]></category>

		<guid isPermaLink="false">http://observerlife.com/?p=669</guid>
		<description><![CDATA[Developing for Mobile Rules: Rule 1: Do NOT use the emulators. Rule 2: Make sure you have: - iPhone or Android (or both ) - S60 - Windows Mobile - ( BlackBerry ) Rule 3: Use media queies State of the Mobile Browsers View more presentations from Peter-Paul Koch. Related Posts:VIM自动化更新脚本推荐:vimanaDid You Know?一段可以避过一般拦截程序的弹出窗口代码Bcastr 3.1 flash [...]]]></description>
			<content:encoded><![CDATA[<p>Developing for Mobile Rules:</p>
<p>Rule 1:<br />
Do NOT use the emulators.</p>
<p>Rule 2:<br />
Make sure you have:<br />
- iPhone or Android (or both )<br />
- S60<br />
- Windows Mobile<br />
- ( BlackBerry )</p>
<p>Rule 3:<br />
Use media queies</p>
<div id="__ss_1653728" style="width: 425px;"><strong><a title="State of the Mobile Browsers" href="http://www.slideshare.net/pp.koch/state-of-the-mobile-browsers">State of the Mobile Browsers</a></strong><object id="__sse1653728" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="425" height="355" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><param name="src" value="http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=yahoomobilebrowsers-090629060205-phpapp02&amp;stripped_title=state-of-the-mobile-browsers" /><param name="name" value="__sse1653728" /><param name="allowfullscreen" value="true" /><embed id="__sse1653728" type="application/x-shockwave-flash" width="425" height="355" src="http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=yahoomobilebrowsers-090629060205-phpapp02&amp;stripped_title=state-of-the-mobile-browsers" name="__sse1653728" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
<div style="padding: 5px 0 12px;">View more <a href="http://www.slideshare.net/">presentations</a> from <a href="http://www.slideshare.net/pp.koch">Peter-Paul Koch</a>.</div>
</div>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://observerlife.com/vimana/" rel="bookmark" class="crp_title">VIM自动化更新脚本推荐:vimana</a></li><li><a href="http://observerlife.com/did-you-know/" rel="bookmark" class="crp_title">Did You Know?</a></li><li><a href="http://observerlife.com/%e4%b8%80%e6%ae%b5%e5%8f%af%e4%bb%a5%e9%81%bf%e8%bf%87%e4%b8%80%e8%88%ac%e6%8b%a6%e6%88%aa%e7%a8%8b%e5%ba%8f%e7%9a%84%e5%bc%b9%e5%87%ba%e7%aa%97%e5%8f%a3%e4%bb%a3%e7%a0%81/" rel="bookmark" class="crp_title">一段可以避过一般拦截程序的弹出窗口代码</a></li><li><a href="http://observerlife.com/bcastr-3-1-flash-%e9%80%9a%e7%94%a8%e5%9b%be%e7%89%87%e8%bd%ae%e6%8d%a2%e6%92%ad%e6%94%be%e5%99%a8/" rel="bookmark" class="crp_title">Bcastr 3.1 flash 通用图片轮换播放器</a></li><li><a href="http://observerlife.com/%e3%80%8a%e5%a3%ab%e5%85%b5%e7%aa%81%e5%87%bb%e3%80%8b%e9%87%8c%e9%92%a2%e4%b8%83%e8%bf%9e%e8%bf%9e%e6%ad%8c/" rel="bookmark" class="crp_title">《士兵突击》里钢七连连歌</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://observerlife.com/sharestate-of-the-mobile-browsers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>InfoQ:在REST/Ajax架构中减少服务器负载和网络流量</title>
		<link>http://observerlife.com/infoq%e5%9c%a8restajax%e6%9e%b6%e6%9e%84%e4%b8%ad%e5%87%8f%e5%b0%91%e6%9c%8d%e5%8a%a1%e5%99%a8%e8%b4%9f%e8%bd%bd%e5%92%8c%e7%bd%91%e7%bb%9c%e6%b5%81%e9%87%8f/</link>
		<comments>http://observerlife.com/infoq%e5%9c%a8restajax%e6%9e%b6%e6%9e%84%e4%b8%ad%e5%87%8f%e5%b0%91%e6%9c%8d%e5%8a%a1%e5%99%a8%e8%b4%9f%e8%bd%bd%e5%92%8c%e7%bd%91%e7%bb%9c%e6%b5%81%e9%87%8f/#comments</comments>
		<pubDate>Thu, 29 Nov 2007 20:05:53 +0000</pubDate>
		<dc:creator>ycg</dc:creator>
				<category><![CDATA[HTML/JavaScript]]></category>
		<category><![CDATA[ajax]]></category>
		<category><![CDATA[http协议]]></category>
		<category><![CDATA[减少负载]]></category>

		<guid isPermaLink="false">http://www.kedy.cn/blog/?p=335</guid>
		<description><![CDATA[Reducing Server Load and Network Traffic in REST/Ajax Architectures 一篇讲如何利用Ajax来降低网络服务器负载和流量的文章，部分观点很有道理。降低网络流量和负载，一直是我最喜欢Ajax的地方，从一个技术人员的角度来说，这才是最实质、最吸引人的地方。另外文章中讲到了如何巧妙利用http 304状态码来减少流量的办法，很有道理。http状态码是我们常见的东西，但是很少有人真正去关注这些东西。而许多新入行的程序员的简历上却往往会写道：熟悉or精通http协议，真是无语。http状态码，在以前也应该经常用到的，但到Ajax使用的多的时候，这个状态码就是一个非常常见的东西了，所以建议每一位做网络程序特别是Web开发的，一定要去认真看看http1.0和1.1协议。 &#160; 相关：HTTP 1.1状态代码及其含义 Related Posts:sablog-x到wordpress数据转换程序&#8211;更正版今日阅读：性能扩展问题要趁早Nokia公开机型产品信息csvPHP 4 end of life announcement &#8212; From:php.net自信的单身族与单身戒指]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.infoq.com/news/2007/11/restful-ajax-http304">Reducing Server Load and Network Traffic in REST/Ajax Architectures</a></p>
<p>一篇讲如何利用Ajax来降低网络服务器负载和流量的文章，部分观点很有道理。降低网络流量和负载，一直是我最喜欢Ajax的地方，从一个技术人员的角度来说，这才是最实质、最吸引人的地方。另外文章中讲到了如何巧妙利用http 304状态码来减少流量的办法，很有道理。http状态码是我们常见的东西，但是很少有人真正去关注这些东西。而许多新入行的程序员的简历上却往往会写道：熟悉or精通http协议，真是无语。http状态码，在以前也应该经常用到的，但到Ajax使用的多的时候，这个状态码就是一个非常常见的东西了，所以建议每一位做网络程序特别是Web开发的，一定要去认真看看http1.0和1.1协议。</p>
<p>&nbsp;</p>
<p>相关：<a href="http://www.kedy.cn/show-116-1.html">HTTP 1.1状态代码及其含义</a></p>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://observerlife.com/sablog-x%e5%88%b0wordpress%e6%95%b0%e6%8d%ae%e8%bd%ac%e6%8d%a2%e7%a8%8b%e5%ba%8f-%e6%9b%b4%e6%ad%a3%e7%89%88/" rel="bookmark" class="crp_title">sablog-x到wordpress数据转换程序&#8211;更正版</a></li><li><a href="http://observerlife.com/%e4%bb%8a%e6%97%a5%e9%98%85%e8%af%bb%ef%bc%9a%e6%80%a7%e8%83%bd%e6%89%a9%e5%b1%95%e9%97%ae%e9%a2%98%e8%a6%81%e8%b6%81%e6%97%a9/" rel="bookmark" class="crp_title">今日阅读：性能扩展问题要趁早</a></li><li><a href="http://observerlife.com/nokia%e5%85%ac%e5%bc%80%e6%9c%ba%e5%9e%8b%e4%ba%a7%e5%93%81%e4%bf%a1%e6%81%afcsv/" rel="bookmark" class="crp_title">Nokia公开机型产品信息csv</a></li><li><a href="http://observerlife.com/php-4-end-of-life-announcement-fromphp-net/" rel="bookmark" class="crp_title">PHP 4 end of life announcement &#8212; From:php.net</a></li><li><a href="http://observerlife.com/%e8%87%aa%e4%bf%a1%e7%9a%84%e5%8d%95%e8%ba%ab%e6%97%8f%e4%b8%8e%e5%8d%95%e8%ba%ab%e6%88%92%e6%8c%87/" rel="bookmark" class="crp_title">自信的单身族与单身戒指</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://observerlife.com/infoq%e5%9c%a8restajax%e6%9e%b6%e6%9e%84%e4%b8%ad%e5%87%8f%e5%b0%91%e6%9c%8d%e5%8a%a1%e5%99%a8%e8%b4%9f%e8%bd%bd%e5%92%8c%e7%bd%91%e7%bb%9c%e6%b5%81%e9%87%8f/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>IE Firefox 浏览器刷新和强制刷新发送的 HTTP Request Header</title>
		<link>http://observerlife.com/ie-firefox-%e6%b5%8f%e8%a7%88%e5%99%a8%e5%88%b7%e6%96%b0%e5%92%8c%e5%bc%ba%e5%88%b6%e5%88%b7%e6%96%b0%e5%8f%91%e9%80%81%e7%9a%84-http-request-header/</link>
		<comments>http://observerlife.com/ie-firefox-%e6%b5%8f%e8%a7%88%e5%99%a8%e5%88%b7%e6%96%b0%e5%92%8c%e5%bc%ba%e5%88%b6%e5%88%b7%e6%96%b0%e5%8f%91%e9%80%81%e7%9a%84-http-request-header/#comments</comments>
		<pubDate>Thu, 09 Aug 2007 07:45:04 +0000</pubDate>
		<dc:creator>ycg</dc:creator>
				<category><![CDATA[HTML/JavaScript]]></category>

		<guid isPermaLink="false">http://www.kedy.cn/blog/?p=198</guid>
		<description><![CDATA[&#160;&#160;&#160;&#160;&#160;&#160; IE Firefox 浏览器刷新和强制刷新发送的 HTTP Request Header 　　Firefox: 　　刷新 F5 　　Cache-Control: max-age=0 　　强制刷新 Ctrl+F5 　　Pragma: no-cache 　　Cache-Control: no-cache 　　IE: 　　刷新 F5 　　If-Modified-Since: Sun, 21 Nov 2004 14:35:21 GMT 　　If-None-Match: &#34;14f598-916-a64a7c40&#34; 　　强制刷新 Ctrl+F5 　　Cache-Control: no-cache Related Posts:HTTP/1.1 Cache-Control header fieldLighttpd+Squid+Apache搭建高效率Web服务器squid反向代理&#8211;转载&#8212;-今日阅读：性能扩展问题要趁早FreeBSD skills everyday &#8212; 11]]></description>
			<content:encoded><![CDATA[<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  IE Firefox 浏览器刷新和强制刷新发送的 HTTP Request Header</p>
<p>　　Firefox:</p>
<p>　　刷新 F5</p>
<p>　　Cache-Control: max-age=0</p>
<p>　　强制刷新 Ctrl+F5</p>
<p>　　Pragma: no-cache</p>
<p>　　Cache-Control: no-cache</p>
<p>　　IE:</p>
<p>　　刷新 F5</p>
<p>　　If-Modified-Since: Sun, 21 Nov 2004 14:35:21 GMT</p>
<p>　　If-None-Match: &quot;14f598-916-a64a7c40&quot;</p>
<p>　　强制刷新 Ctrl+F5</p>
<p>　　Cache-Control: no-cache</p>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://observerlife.com/http1-1-cache-control-header-field/" rel="bookmark" class="crp_title">HTTP/1.1 Cache-Control header field</a></li><li><a href="http://observerlife.com/lighttpdsquidapache%e6%90%ad%e5%bb%ba%e9%ab%98%e6%95%88%e7%8e%87web%e6%9c%8d%e5%8a%a1%e5%99%a8/" rel="bookmark" class="crp_title">Lighttpd+Squid+Apache搭建高效率Web服务器</a></li><li><a href="http://observerlife.com/squid%e5%8f%8d%e5%90%91%e4%bb%a3%e7%90%86-%e8%bd%ac%e8%bd%bd/" rel="bookmark" class="crp_title">squid反向代理&#8211;转载&#8212;-</a></li><li><a href="http://observerlife.com/%e4%bb%8a%e6%97%a5%e9%98%85%e8%af%bb%ef%bc%9a%e6%80%a7%e8%83%bd%e6%89%a9%e5%b1%95%e9%97%ae%e9%a2%98%e8%a6%81%e8%b6%81%e6%97%a9/" rel="bookmark" class="crp_title">今日阅读：性能扩展问题要趁早</a></li><li><a href="http://observerlife.com/freebsd-skills-everyday-11/" rel="bookmark" class="crp_title">FreeBSD skills everyday &#8212; 11</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://observerlife.com/ie-firefox-%e6%b5%8f%e8%a7%88%e5%99%a8%e5%88%b7%e6%96%b0%e5%92%8c%e5%bc%ba%e5%88%b6%e5%88%b7%e6%96%b0%e5%8f%91%e9%80%81%e7%9a%84-http-request-header/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>两个CSS在线处理网站</title>
		<link>http://observerlife.com/%e4%b8%a4%e4%b8%aacss%e5%9c%a8%e7%ba%bf%e5%a4%84%e7%90%86%e7%bd%91%e7%ab%99/</link>
		<comments>http://observerlife.com/%e4%b8%a4%e4%b8%aacss%e5%9c%a8%e7%ba%bf%e5%a4%84%e7%90%86%e7%bd%91%e7%ab%99/#comments</comments>
		<pubDate>Mon, 14 May 2007 18:29:24 +0000</pubDate>
		<dc:creator>ycg</dc:creator>
				<category><![CDATA[HTML/JavaScript]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[优化]]></category>
		<category><![CDATA[在线]]></category>

		<guid isPermaLink="false">http://www.kedy.cn/blog/?p=153</guid>
		<description><![CDATA[可以在不影响页面显示效果的前提下减少你的CSS代码,我测试了一个css，还真有效果,优化掉近10%。[ 链接 http://flumpcakes.co.uk/css/optimiser/&#160;] 这个则可以把CSS紧凑化[ 链接 http://www.cssdrive.com/index.php/main/csscompressor&#160;] [Copy From : http://cnc.sablog.net/blog/] Related Posts:upgrade《士兵突击》- 许三多是个成功人士《士兵突击》- 当高城遇上袁朗（二）《士兵突击》- 观后感之史今篇《士兵突击》- 任是无情也动人，论袁朗]]></description>
			<content:encoded><![CDATA[<p>可以在不影响页面显示效果的前提下减少你的CSS代码,我测试了一个css，还真有效果,优化掉近10%。<br />[ 链接 <a target="_blank" href="http://flumpcakes.co.uk/css/optimiser/">http://flumpcakes.co.uk/css/optimiser/</a>&nbsp;]</p>
<div class="content">
<p>这个则可以把CSS紧凑化<br />[ 链接 <a target="_blank" href="http://www.cssdrive.com/index.php/main/csscompressor">http://www.cssdrive.com/index.php/main/csscompressor</a>&nbsp;]</p>
<p>[Copy From : <a href="http://cnc.sablog.net/blog/">http://cnc.sablog.net/blog/</a>]</p>
</div>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://observerlife.com/upgrade/" rel="bookmark" class="crp_title">upgrade</a></li><li><a href="http://observerlife.com/%e3%80%8a%e5%a3%ab%e5%85%b5%e7%aa%81%e5%87%bb%e3%80%8b-%e8%ae%b8%e4%b8%89%e5%a4%9a%e6%98%af%e4%b8%aa%e6%88%90%e5%8a%9f%e4%ba%ba%e5%a3%ab/" rel="bookmark" class="crp_title">《士兵突击》- 许三多是个成功人士</a></li><li><a href="http://observerlife.com/%e3%80%8a%e5%a3%ab%e5%85%b5%e7%aa%81%e5%87%bb%e3%80%8b-%e5%bd%93%e9%ab%98%e5%9f%8e%e9%81%87%e4%b8%8a%e8%a2%81%e6%9c%97%ef%bc%88%e4%ba%8c%ef%bc%89/" rel="bookmark" class="crp_title">《士兵突击》- 当高城遇上袁朗（二）</a></li><li><a href="http://observerlife.com/%e3%80%8a%e5%a3%ab%e5%85%b5%e7%aa%81%e5%87%bb%e3%80%8b-%e8%a7%82%e5%90%8e%e6%84%9f%e4%b9%8b%e5%8f%b2%e4%bb%8a%e7%af%87/" rel="bookmark" class="crp_title">《士兵突击》- 观后感之史今篇</a></li><li><a href="http://observerlife.com/%e3%80%8a%e5%a3%ab%e5%85%b5%e7%aa%81%e5%87%bb%e3%80%8b-%e4%bb%bb%e6%98%af%e6%97%a0%e6%83%85%e4%b9%9f%e5%8a%a8%e4%ba%ba%ef%bc%8c%e8%ae%ba%e8%a2%81%e6%9c%97/" rel="bookmark" class="crp_title">《士兵突击》- 任是无情也动人，论袁朗</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://observerlife.com/%e4%b8%a4%e4%b8%aacss%e5%9c%a8%e7%ba%bf%e5%a4%84%e7%90%86%e7%bd%91%e7%ab%99/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Firefox下的自动换行居然无效</title>
		<link>http://observerlife.com/firefox%e4%b8%8b%e7%9a%84%e8%87%aa%e5%8a%a8%e6%8d%a2%e8%a1%8c%e5%b1%85%e7%84%b6%e6%97%a0%e6%95%88/</link>
		<comments>http://observerlife.com/firefox%e4%b8%8b%e7%9a%84%e8%87%aa%e5%8a%a8%e6%8d%a2%e8%a1%8c%e5%b1%85%e7%84%b6%e6%97%a0%e6%95%88/#comments</comments>
		<pubDate>Mon, 20 Nov 2006 03:23:13 +0000</pubDate>
		<dc:creator>ycg</dc:creator>
				<category><![CDATA[HTML/JavaScript]]></category>
		<category><![CDATA[firefox]]></category>

		<guid isPermaLink="false">http://www.kedy.cn/blog/?p=126</guid>
		<description><![CDATA[在IE下，使用word-wrap/table-layout等都可以让作用域内的字符自动换行。FireFox下够郁闷的，愣是不支持自动换行这一特性。虽然这是IE的一个特性，但毕竟这个是非常容易遇到的情况，我觉得应该引入进来。这里基本上都长草了，没时间来看看。最近比较忙，连续两周肯定没有好好休息的时间，连高中同学的婚礼也参加不了了。实在是有些过意不去。他是我高中最好的同学，而且曾经是相对于他家人，更能听进我的话。Bless! Related Posts:Firefox和IE下display属性不兼容的解决办法简单检测操作系统是否是64位系统的方法php版《士兵突击》-最有哲理的话（语录）技巧: 使用truss、strace或ltrace诊断软件的&#34;疑难杂症&#34;freebsd7安装手册-更新ports 和src]]></description>
			<content:encoded><![CDATA[<p>在IE下，使用word-wrap/table-layout等都可以让作用域内的字符自动换行。FireFox下够郁闷的，愣是不支持自动换行这一特性。虽然这是IE的一个特性，但毕竟这个是非常容易遇到的情况，我觉得应该引入进来。<br />这里基本上都长草了，没时间来看看。最近比较忙，连续两周肯定没有好好休息的时间，连高中同学的婚礼也参加不了了。实在是有些过意不去。他是我高中最好的同学，而且曾经是相对于他家人，更能听进我的话。<br />Bless!</p>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://observerlife.com/firefox%e5%92%8cie%e4%b8%8bdisplay%e5%b1%9e%e6%80%a7%e4%b8%8d%e5%85%bc%e5%ae%b9%e7%9a%84%e8%a7%a3%e5%86%b3%e5%8a%9e%e6%b3%95/" rel="bookmark" class="crp_title">Firefox和IE下display属性不兼容的解决办法</a></li><li><a href="http://observerlife.com/%e7%ae%80%e5%8d%95%e6%a3%80%e6%b5%8b%e6%93%8d%e4%bd%9c%e7%b3%bb%e7%bb%9f%e6%98%af%e5%90%a6%e6%98%af64%e4%bd%8d%e7%b3%bb%e7%bb%9f%e7%9a%84%e6%96%b9%e6%b3%95php%e7%89%88/" rel="bookmark" class="crp_title">简单检测操作系统是否是64位系统的方法php版</a></li><li><a href="http://observerlife.com/%e3%80%8a%e5%a3%ab%e5%85%b5%e7%aa%81%e5%87%bb%e3%80%8b-%e6%9c%80%e6%9c%89%e5%93%b2%e7%90%86%e7%9a%84%e8%af%9d%ef%bc%88%e8%af%ad%e5%bd%95%ef%bc%89/" rel="bookmark" class="crp_title">《士兵突击》-最有哲理的话（语录）</a></li><li><a href="http://observerlife.com/%e6%8a%80%e5%b7%a7-%e4%bd%bf%e7%94%a8truss%e3%80%81strace%e6%88%96ltrace%e8%af%8a%e6%96%ad%e8%bd%af%e4%bb%b6%e7%9a%84%e7%96%91%e9%9a%be%e6%9d%82%e7%97%87/" rel="bookmark" class="crp_title">技巧: 使用truss、strace或ltrace诊断软件的&quot;疑难杂症&quot;</a></li><li><a href="http://observerlife.com/freebsd7%e5%ae%89%e8%a3%85%e6%89%8b%e5%86%8c-%e6%9b%b4%e6%96%b0ports-%e5%92%8csrc/" rel="bookmark" class="crp_title">freebsd7安装手册-更新ports 和src</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://observerlife.com/firefox%e4%b8%8b%e7%9a%84%e8%87%aa%e5%8a%a8%e6%8d%a2%e8%a1%8c%e5%b1%85%e7%84%b6%e6%97%a0%e6%95%88/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Javascript的IE和Firefox兼容性汇编</title>
		<link>http://observerlife.com/javascript%e7%9a%84ie%e5%92%8cfirefox%e5%85%bc%e5%ae%b9%e6%80%a7%e6%b1%87%e7%bc%96/</link>
		<comments>http://observerlife.com/javascript%e7%9a%84ie%e5%92%8cfirefox%e5%85%bc%e5%ae%b9%e6%80%a7%e6%b1%87%e7%bc%96/#comments</comments>
		<pubDate>Fri, 03 Nov 2006 03:31:24 +0000</pubDate>
		<dc:creator>ycg</dc:creator>
				<category><![CDATA[HTML/JavaScript]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[ie]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[兼容]]></category>

		<guid isPermaLink="false">http://www.kedy.cn/blog/?p=125</guid>
		<description><![CDATA[以下以 IE 代替 Internet Explorer，以 MF 代替 Mozzila Firefox 1. document.form.item 问题 (1)现有问题： 现有代码中存在许多 document.formName.item(&#34;itemName&#34;) 这样的语句，不能在 MF 下运行 (2)解决方法： 改用 document.formName.elements[&#34;elementName&#34;] (3)其它 参见 2 2. 集合类对象问题 (1)现有问题： 现有代码中许多集合类对象取用时使用 ()，IE 能接受，MF 不能。 (2)解决方法： 改用 [] 作为下标运算。如：document.forms(&#34;formName&#34;) 改为 document.forms[&#34;formName&#34;]。 又如：document.getElementsByName(&#34;inputName&#34;)(1) 改为 document.getElementsByName(&#34;inputName&#34;)[1] (3)其它 3. window.event (1)现有问题： 使用 window.event 无法在 MF 上运行 (2)解决方法： MF 的 event 只能在事件发生的现场使用，此问题暂无法解决。可以这样变通： 原代码(可在IE中运行)： [...]]]></description>
			<content:encoded><![CDATA[<div id="vn" style="PADDING-RIGHT: 15px; PADDING-LEFT: 15px; PADDING-BOTTOM: 15px; OVERFLOW: auto; WORD-BREAK: break-all; PADDING-TOP: 15px">
<p>以下以 IE 代替 Internet Explorer，以 MF 代替 Mozzila Firefox </p>
<p>1. document.form.item 问题 <br />(1)现有问题： <br />现有代码中存在许多 document.formName.item(&quot;itemName&quot;) 这样的语句，不能在 MF 下运行 <br />(2)解决方法： <br />改用 document.formName.elements[&quot;elementName&quot;] <br />(3)其它 <br />参见 2 </p>
<p>2. 集合类对象问题 <br />(1)现有问题： <br />现有代码中许多集合类对象取用时使用 ()，IE 能接受，MF 不能。 <br />(2)解决方法： <br />改用 [] 作为下标运算。如：document.forms(&quot;formName&quot;) 改为 document.forms[&quot;formName&quot;]。 <br />又如：document.getElementsByName(&quot;inputName&quot;)(1) 改为 document.getElementsByName(&quot;inputName&quot;)[1] <br />(3)其它 </p>
<p>3. window.event <br />(1)现有问题： <br />使用 window.event 无法在 MF 上运行 <br />(2)解决方法： <br />MF 的 event 只能在事件发生的现场使用，此问题暂无法解决。可以这样变通： <br />原代码(可在IE中运行)： <br />&lt;input type=&quot;button&quot; name=&quot;someButton&quot; value=&quot;提交&quot; onclick=&quot;javascript:gotoSubmit()&quot;/&gt; <br />&#8230; <br />&lt;script language=&quot;javascript&quot;&gt; <br />function gotoSubmit() { <br />&#8230; <br />alert(window.event); // use window.event <br />&#8230; <br />} <br />&lt;/script&gt; </p>
<p>新代码(可在IE和MF中运行)： <br />&lt;input type=&quot;button&quot; name=&quot;someButton&quot; value=&quot;提交&quot; onclick=&quot;javascript:gotoSubmit(event)&quot;/&gt; <br />&#8230; <br />&lt;script language=&quot;javascript&quot;&gt; <br />function gotoSubmit(evt) { <br />evt = evt ? evt : (window.event ? window.event : null); <br />&#8230; <br />alert(evt); // use evt <br />&#8230; <br />} <br />&lt;/script&gt; <br />此外，如果新代码中第一行不改，与老代码一样的话(即 gotoSubmit 调用没有给参数)，则仍然只能在IE中运行，但不会出错。所以，这种方案 tpl 部分仍与老代码兼容。 </p>
<p>4. HTML 对象的 id 作为对象名的问题 <br />(1)现有问题 <br />在 IE 中，HTML 对象的 ID 可以作为 document 的下属对象变量名直接使用。在 MF 中不能。 <br />(2)解决方法 <br />用 getElementById(&quot;idName&quot;) 代替 idName 作为对象变量使用。 </p>
<p>5. 用idName字符串取得对象的问题 <br />(1)现有问题 <br />在IE中，利用 eval(idName) 可以取得 id 为 idName 的 HTML 对象，在MF 中不能。 <br />(2)解决方法 <br />用 getElementById(idName) 代替 eval(idName)。 </p>
<p>6. 变量名与某 HTML 对象 id 相同的问题 <br />(1)现有问题 <br />在 MF 中，因为对象 id 不作为 HTML 对象的名称，所以可以使用与 HTML 对象 id 相同的变量名，IE 中不能。 <br />(2)解决方法 <br />在声明变量时，一律加上 var ，以避免歧义，这样在 IE 中亦可正常运行。 <br />此外，最好不要取与 HTML 对象 id 相同的变量名，以减少错误。 <br />(3)其它 <br />参见 问题4 </p>
<p>7. event.x 与 event.y 问题 <br />(1)现有问题 <br />在IE 中，event 对象有 x, y 属性，MF中没有。 <br />(2)解决方法 <br />在MF中，与event.x 等效的是 event.pageX。但event.pageX IE中没有。 <br />故采用 event.clientX 代替 event.x。在IE 中也有这个变量。 <br />event.clientX 与 event.pageX 有微妙的差别（当整个页面有滚动条的时候），不过大多数时候是等效的。 </p>
<p>如果要完全一样，可以稍麻烦些： <br />mX = event.x ? event.x : event.pageX; <br />然后用 mX 代替 event.x <br />(3)其它 <br />event.layerX 在 IE 与 MF 中都有，具体意义有无差别尚未试验。 </p>
<p>8. 关于frame <br />(1)现有问题 <br />在 IE中 可以用window.testFrame取得该frame，mf中不行 <br />(2)解决方法 <br />在frame的使用方面mf和ie的最主要的区别是： <br />如果在frame标签中书写了以下属性： <br />&lt;frame src=&quot;xx.htm&quot; id=&quot;frameId&quot; name=&quot;frameName&quot; /&gt; <br />那么ie可以通过id或者name访问这个frame对应的window对象 <br />而mf只可以通过name来访问这个frame对应的window对象 <br />例如如果上述frame标签写在最上层的window里面的htm里面，那么可以这样访问 <br />ie： window.top.frameId或者window.top.frameName来访问这个window对象 <br />mf： 只能这样window.top.frameName来访问这个window对象 </p>
<p>另外，在mf和ie中都可以使用window.top.document.getElementById(&quot;frameId&quot;)来访问frame标签 <br />并且可以通过window.top.document.getElementById(&quot;testFrame&quot;).src = &#8216;xx.htm&#8217;来切换frame的内容 <br />也都可以通过window.top.frameName.location = &#8216;xx.htm&#8217;来切换frame的内容 <br />关于frame和window的描述可以参见bbs的&lsquo;window与frame&rsquo;文章 <br />以及/test/js/test_frame/目录下面的测试 <br />&#8212;-adun 2004.12.09修改 </p>
<p>9. 在mf中，自己定义的属性必须getAttribute()取得 <br />10.在mf中没有 parentElement parement.children 而用 <br />parentNode parentNode.childNodes <br />childNodes的下标的含义在IE和MF中不同，MF使用DOM规范，childNodes中会插入空白文本节点。 <br />一般可以通过node.getElementsByTagName()来回避这个问题。 <br />当html中节点缺失时，IE和MF对parentNode的解释不同，例如 <br />&lt;form&gt; <br />&lt;table&gt; <br />&lt;input/&gt; <br />&lt;/table&gt; <br />&lt;/form&gt; <br />MF中input.parentNode的值为form, 而IE中input.parentNode的值为空节点 </p>
<p>MF中节点没有removeNode方法，必须使用如下方法 node.parentNode.removeChild(node) </p>
<p>11.const 问题 <br />(1)现有问题: <br />在 IE 中不能使用 const 关键字。如 const constVar = 32; 在IE中这是语法错误。 <br />(2)解决方法: <br />不使用 const ，以 var 代替。 </p>
<p>12. body 对象 <br />MF的body在body标签没有被浏览器完全读入之前就存在，而IE则必须在body完全被读入之后才存在 </p>
<p>13. url encoding <br />在js中如果书写url就直接写&amp;不要写&amp;例如var url = &#8216;xx.jsp?objectName=xx&amp;objectEvent=xxx&#8217;; <br />frm.action = url那么很有可能url不会被正常显示以至于参数没有正确的传到服务器 <br />一般会服务器报错参数没有找到 <br />当然如果是在tpl中例外，因为tpl中符合xml规范，要求&amp;书写为&amp; <br />一般MF无法识别js中的&amp;</p>
<p>14. nodeName 和 tagName 问题 <br />(1)现有问题： <br />在MF中，所有节点均有 nodeName 值，但 textNode 没有 tagName 值。在 IE 中，nodeName 的使用好象 <br />有问题（具体情况没有测试，但我的IE已经死了好几次）。 <br />(2)解决方法： <br />使用 tagName，但应检测其是否为空。 </p>
<p>15. 元素属性 <br />IE下 input.type属性为只读，但是MF下可以修改</p>
<p>16. document.getElementsByName() 和 document.all[name] 的问题 <br />(1)现有问题： <br />在 IE 中，getElementsByName()、document.all[name] 均不能用来取得 div 元素（是否还有其它不能取的元素还不知道）。</p>
</div>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://observerlife.com/%e8%bd%acjavascript%e7%9a%84ie%e5%92%8cfirefox%e5%85%bc%e5%ae%b9%e6%80%a7%e6%b1%87%e7%bc%96/" rel="bookmark" class="crp_title">[转]Javascript的IE和Firefox兼容性汇编</a></li><li><a href="http://observerlife.com/%e4%b8%80%e6%ae%b5%e5%8f%af%e4%bb%a5%e9%81%bf%e8%bf%87%e4%b8%80%e8%88%ac%e6%8b%a6%e6%88%aa%e7%a8%8b%e5%ba%8f%e7%9a%84%e5%bc%b9%e5%87%ba%e7%aa%97%e5%8f%a3%e4%bb%a3%e7%a0%81/" rel="bookmark" class="crp_title">一段可以避过一般拦截程序的弹出窗口代码</a></li><li><a href="http://observerlife.com/js%e2%80%94%e2%80%94%e8%ae%be%e7%bd%ae%e3%80%81%e8%8e%b7%e5%8f%96%e3%80%81%e5%88%a0%e9%99%a4-cookie-%e7%9a%84%e5%8a%9f%e8%83%bd/" rel="bookmark" class="crp_title">JS——设置、获取、删除 cookie 的功能</a></li><li><a href="http://observerlife.com/window-location-href%e5%9c%a8firefox%e4%b8%ad%e4%b8%8d%e5%85%bc%e5%ae%b9%e7%9a%84%e8%a7%a3%e5%86%b3%e5%8a%9e%e6%b3%95%e5%8e%9f%e5%88%9b/" rel="bookmark" class="crp_title">window.location.href在firefox中不兼容的解决办法[原创]</a></li><li><a href="http://observerlife.com/%e5%b8%b8%e7%94%a8js%e8%af%ad%e5%8f%a5%e8%bd%ac/" rel="bookmark" class="crp_title">常用JS语句(转)</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://observerlife.com/javascript%e7%9a%84ie%e5%92%8cfirefox%e5%85%bc%e5%ae%b9%e6%80%a7%e6%b1%87%e7%bc%96/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>一段可以避过一般拦截程序的弹出窗口代码</title>
		<link>http://observerlife.com/%e4%b8%80%e6%ae%b5%e5%8f%af%e4%bb%a5%e9%81%bf%e8%bf%87%e4%b8%80%e8%88%ac%e6%8b%a6%e6%88%aa%e7%a8%8b%e5%ba%8f%e7%9a%84%e5%bc%b9%e5%87%ba%e7%aa%97%e5%8f%a3%e4%bb%a3%e7%a0%81/</link>
		<comments>http://observerlife.com/%e4%b8%80%e6%ae%b5%e5%8f%af%e4%bb%a5%e9%81%bf%e8%bf%87%e4%b8%80%e8%88%ac%e6%8b%a6%e6%88%aa%e7%a8%8b%e5%ba%8f%e7%9a%84%e5%bc%b9%e5%87%ba%e7%aa%97%e5%8f%a3%e4%bb%a3%e7%a0%81/#comments</comments>
		<pubDate>Thu, 26 Oct 2006 08:10:13 +0000</pubDate>
		<dc:creator>ycg</dc:creator>
				<category><![CDATA[HTML/JavaScript]]></category>
		<category><![CDATA[代码]]></category>
		<category><![CDATA[弹出]]></category>
		<category><![CDATA[弹窗]]></category>

		<guid isPermaLink="false">http://www.kedy.cn/blog/?p=121</guid>
		<description><![CDATA[现在一般的IE弹出窗口都会被xp sp2或者其他的拦截程序干掉，根本没有机会弹出。但也不是没有办法，毕竟，许多流氓网站还是在弹出。那么他们是怎么做到弹出窗口的呢？这几天小研究了一下。道理是这样的，为了能让大多网页正常运行，弹出窗口的默认规则都不是特别严格。但遇到window.open或者利用模式对话框的做法，是基本上不可行了。那么应该怎么做呢？需要利用的就是这个不严格的规则。利用一些控件，比如说Flash，或者realone插件，至于MPC可以不可以，我没有遇到过，也没有做过相关的开发，实在不太清楚。不过我想，应该可以的。 废话少说，先来说说利用Flash弹出窗口吧。详细研究过Flash的Action Script的朋友可能比较清楚，在AS里同样也有一个window.open，而一般拦截弹出窗口程序对其ActionScript的限制是比较少的。(window.open参数和javascript的window.open基本一样，在这里就不详说了。)就利用这一点。有两个办法，一个是做一个比较小的Flash，代码里加上window.open这个东东。另一种办法是完全使用js代码，直接用js模拟一个Flash，我具体说一下这个办法。 首先，在目标页面上document.write一个id为popup的层，并设置宽度和高度都为0，显示属性为hidden。这样保证在载入页面是用户看不到这个东东。[php]document.writeln(&#8216;&#60;div id=popup style=&#34;top: 0; width: 0; height: 0; position: relative; visibility:hidden;&#34;&#62;&#60;/div&#62;&#8217;);[/php] 然后，是在这个层里创建一个Flash控件。[php]var obj = document.getElementById(&#8216;popup&#8217;);obj.innerHTML += &#8216;&#60;div&#62;&#60;object id=&#34;popupObj&#34; width=0 height=0 classid=&#34;clsid:2D360201-FFF5-11d1-8D03-00A0C959BC0A&#34; codebase= &#34;http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0&#34;&#62;&#60;param name=&#34;ActivateApplets&#34; value=&#34;1&#34;&#62;&#60;param name=&#34;ActivateActiveXControls&#34; value=&#34;1&#34;&#62;&#60;/object&#62;&#60;/div&#62;&#8217;;[/php]实际上，这一步就完成了在页面上建立了一个Flash对象，如果正常操作的话，可能可以做一些Flash比较有优势的Action,不过今天目的不在这。 最重要的一步，执行弹出窗口window.open代码。这里需要利用DOM来给刚才建立的Flash添加代码：[php]pObj.DOM.Script.execScript(&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &#34;function openPopup() {var cwidth=820;cheight=660; l=(screen.Width-cwidth)*.5; t=(screen.Height-cheight)*.5; popwin = window.open( &#8216;http://www.kedy.cn&#8217;,'ads&#8217;,'height=&#8217;+cheight+&#8217;,width=&#8217;+cwidth+&#8217;,left=&#8217;+l+&#8217;,top=&#8217;+t+&#8217;,toolbar=no,status=no,location=no,menubar=no,scrollbars=no,resizable=no&#8217;); if (popwin) {popwin.blur();} return popwin;}&#34;);[/php]然后再运行这个function[php]pObj.DOM.Script.paypopupOpen()[/php] 到这里其实核心的东西就已经完成了。具体的实现我就不给出实例代码了，毕竟，这个东东会有一些歪用途。如果实在想要的话，那就去找一家流氓网站，能自动弹窗的。然后学习它的代码吧。呵呵，流氓也不是一无是处啊。这点东西我就是从流氓网站上学来的。~~~ Related Posts:SaBlog-X屏蔽机器人垃圾评论的方法FreeBSD skills everyday &#8212; 11Bcastr 3.1 [...]]]></description>
			<content:encoded><![CDATA[<p>现在一般的IE弹出窗口都会被xp sp2或者其他的拦截程序干掉，根本没有机会弹出。但也不是没有办法，毕竟，许多流氓网站还是在弹出。那么他们是怎么做到弹出窗口的呢？这几天小研究了一下。道理是这样的，为了能让大多网页正常运行，弹出窗口的默认规则都不是特别严格。但遇到window.open或者利用模式对话框的做法，是基本上不可行了。那么应该怎么做呢？需要利用的就是这个不严格的规则。利用一些控件，比如说Flash，或者realone插件，至于MPC可以不可以，我没有遇到过，也没有做过相关的开发，实在不太清楚。不过我想，应该可以的。</p>
<p>废话少说，先来说说利用Flash弹出窗口吧。详细研究过Flash的Action Script的朋友可能比较清楚，在AS里同样也有一个window.open，而一般拦截弹出窗口程序对其ActionScript的限制是比较少的。(window.open参数和javascript的window.open基本一样，在这里就不详说了。)就利用这一点。有两个办法，一个是做一个比较小的Flash，代码里加上window.open这个东东。另一种办法是完全使用js代码，直接用js模拟一个Flash，我具体说一下这个办法。</p>
<p>首先，在目标页面上document.write一个id为popup的层，并设置宽度和高度都为0，显示属性为hidden。这样保证在载入页面是用户看不到这个东东。<br />[php]document.writeln(&#8216;&lt;div id=popup style=&quot;top: 0; width: 0; height: 0; position: relative; visibility:hidden;&quot;&gt;&lt;/div&gt;&#8217;);[/php]</p>
<p>然后，是在这个层里创建一个Flash控件。<br />[php]<br />var obj = document.getElementById(&#8216;popup&#8217;);<br />obj.innerHTML += &#8216;&lt;div&gt;&lt;object id=&quot;popupObj&quot; width=0 height=0 classid=&quot;clsid:2D360201-FFF5-11d1-8D03-00A0C959BC0A&quot; codebase= &quot;<a href="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0&quot;&gt;&lt;param">http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0&quot;&gt;&lt;param</a> name=&quot;ActivateApplets&quot; value=&quot;1&quot;&gt;&lt;param name=&quot;ActivateActiveXControls&quot; value=&quot;1&quot;&gt;&lt;/object&gt;&lt;/div&gt;&#8217;;<br />[/php]<br />实际上，这一步就完成了在页面上建立了一个Flash对象，如果正常操作的话，可能可以做一些Flash比较有优势的Action,不过今天目的不在这。</p>
<p>最重要的一步，执行弹出窗口window.open代码。这里需要利用DOM来给刚才建立的Flash添加代码：<br />[php]pObj.DOM.Script.execScript(<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &quot;function openPopup() {var cwidth=820;cheight=660; l=(screen.Width-cwidth)*.5; t=(screen.Height-cheight)*.5; popwin = window.open( &#8216;http://www.kedy.cn&#8217;,'ads&#8217;,'height=&#8217;+cheight+&#8217;,width=&#8217;+cwidth+&#8217;,left=&#8217;+l+&#8217;,top=&#8217;+t+&#8217;,toolbar=no,status=no,location=no,menubar=no,scrollbars=no,resizable=no&#8217;); if (popwin) {popwin.blur();} return popwin;}&quot;);[/php]<br />然后再运行这个function<br />[php]pObj.DOM.Script.paypopupOpen()[/php]</p>
<p>到这里其实核心的东西就已经完成了。具体的实现我就不给出实例代码了，毕竟，这个东东会有一些歪用途。如果实在想要的话，那就去找一家流氓网站，能自动弹窗的。然后学习它的代码吧。呵呵，流氓也不是一无是处啊。这点东西我就是从流氓网站上学来的。~~~</p>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://observerlife.com/sablog-x%e5%b1%8f%e8%94%bd%e6%9c%ba%e5%99%a8%e4%ba%ba%e5%9e%83%e5%9c%be%e8%af%84%e8%ae%ba%e7%9a%84%e6%96%b9%e6%b3%95/" rel="bookmark" class="crp_title">SaBlog-X屏蔽机器人垃圾评论的方法</a></li><li><a href="http://observerlife.com/freebsd-skills-everyday-11/" rel="bookmark" class="crp_title">FreeBSD skills everyday &#8212; 11</a></li><li><a href="http://observerlife.com/bcastr-3-1-flash-%e9%80%9a%e7%94%a8%e5%9b%be%e7%89%87%e8%bd%ae%e6%8d%a2%e6%92%ad%e6%94%be%e5%99%a8/" rel="bookmark" class="crp_title">Bcastr 3.1 flash 通用图片轮换播放器</a></li><li><a href="http://observerlife.com/upgrade/" rel="bookmark" class="crp_title">upgrade</a></li><li><a href="http://observerlife.com/freebsd-skills-everyday-8/" rel="bookmark" class="crp_title">FreeBSD skills everyday &#8212; 8</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://observerlife.com/%e4%b8%80%e6%ae%b5%e5%8f%af%e4%bb%a5%e9%81%bf%e8%bf%87%e4%b8%80%e8%88%ac%e6%8b%a6%e6%88%aa%e7%a8%8b%e5%ba%8f%e7%9a%84%e5%bc%b9%e5%87%ba%e7%aa%97%e5%8f%a3%e4%bb%a3%e7%a0%81/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cache-Control消息头域说明</title>
		<link>http://observerlife.com/cache-control%e6%b6%88%e6%81%af%e5%a4%b4%e5%9f%9f%e8%af%b4%e6%98%8e/</link>
		<comments>http://observerlife.com/cache-control%e6%b6%88%e6%81%af%e5%a4%b4%e5%9f%9f%e8%af%b4%e6%98%8e/#comments</comments>
		<pubDate>Tue, 22 Aug 2006 18:21:14 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[HTML/JavaScript]]></category>

		<guid isPermaLink="false">http://www.kedy.cn/blog/?p=109</guid>
		<description><![CDATA[Cache-Control指定请求和响应遵循的缓存机制。在请求消息或响应消息中设置Cache-Control并不会修改另一个消息处理过程中的缓存处理过程。请求时的缓存指令包括no-cache、no-store、max-age、max-stale、min-fresh、only-if-cached，响应消息中的指令包括public、private、no-cache、no-store、no-transform、must-revalidate、proxy-revalidate、max-age。各个消息中的指令含义如下： Public指示响应可被任何缓存区缓存。 Private指示对于单个用户的整个或部分响应消息，不能被共享缓存处理。这允许服务器仅仅描述当用户的部分响应消息，此响应消息对于其他用户的请求无效。 no-cache指示请求或响应消息不能缓存 no-store用于防止重要的信息被无意的发布。在请求消息中发送将使得请求和响应消息都不使用缓存。 max-age指示客户机可以接收生存期不大于指定时间（以秒为单位）的响应。 min-fresh指示客户机可以接收响应时间小于当前时间加上指定时间的响应。 max-stale指示客户机可以接收超出超时期间的响应消息。如果指定max-stale消息的值，那么客户机可以接收超出超时期指定值之内的响应消息。 Related Posts:HTTP/1.1 Cache-Control header fieldFreeBSD 虚拟内存的浅析IE Firefox 浏览器刷新和强制刷新发送的 HTTP Request HeaderLighttpd+Squid+Apache搭建高效率Web服务器Squid请求处理的典型流程]]></description>
			<content:encoded><![CDATA[<p> Cache-Control指定请求和响应遵循的缓存机制。在请求消息或响应消息中设置Cache-Control并不会修改另一个消息处理过程中的缓存处理过程。请求时的缓存指令包括no-cache、no-store、max-age、max-stale、min-fresh、only-if-cached，响应消息中的指令包括public、private、no-cache、no-store、no-transform、must-revalidate、proxy-revalidate、max-age。各个消息中的指令含义如下： </p>
<p>Public指示响应可被任何缓存区缓存。<br />
Private指示对于单个用户的整个或部分响应消息，不能被共享缓存处理。这允许服务器仅仅描述当用户的部分响应消息，此响应消息对于其他用户的请求无效。<br />
no-cache指示请求或响应消息不能缓存<br />
no-store用于防止重要的信息被无意的发布。在请求消息中发送将使得请求和响应消息都不使用缓存。<br />
max-age指示客户机可以接收生存期不大于指定时间（以秒为单位）的响应。<br />
min-fresh指示客户机可以接收响应时间小于当前时间加上指定时间的响应。<br />
max-stale指示客户机可以接收超出超时期间的响应消息。如果指定max-stale消息的值，那么客户机可以接收超出超时期指定值之内的响应消息。</p>
<div id="crp_related"><h3>Related Posts:</h3><ul><li><a href="http://observerlife.com/http1-1-cache-control-header-field/" rel="bookmark" class="crp_title">HTTP/1.1 Cache-Control header field</a></li><li><a href="http://observerlife.com/freebsd-%e8%99%9a%e6%8b%9f%e5%86%85%e5%ad%98%e7%9a%84%e6%b5%85%e6%9e%90/" rel="bookmark" class="crp_title">FreeBSD 虚拟内存的浅析</a></li><li><a href="http://observerlife.com/ie-firefox-%e6%b5%8f%e8%a7%88%e5%99%a8%e5%88%b7%e6%96%b0%e5%92%8c%e5%bc%ba%e5%88%b6%e5%88%b7%e6%96%b0%e5%8f%91%e9%80%81%e7%9a%84-http-request-header/" rel="bookmark" class="crp_title">IE Firefox 浏览器刷新和强制刷新发送的 HTTP Request Header</a></li><li><a href="http://observerlife.com/lighttpdsquidapache%e6%90%ad%e5%bb%ba%e9%ab%98%e6%95%88%e7%8e%87web%e6%9c%8d%e5%8a%a1%e5%99%a8/" rel="bookmark" class="crp_title">Lighttpd+Squid+Apache搭建高效率Web服务器</a></li><li><a href="http://observerlife.com/squid%e8%af%b7%e6%b1%82%e5%a4%84%e7%90%86%e7%9a%84%e5%85%b8%e5%9e%8b%e6%b5%81%e7%a8%8b/" rel="bookmark" class="crp_title">Squid请求处理的典型流程</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://observerlife.com/cache-control%e6%b6%88%e6%81%af%e5%a4%b4%e5%9f%9f%e8%af%b4%e6%98%8e/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
