<?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>某人的栖息地 &#187; javascript</title>
	<atom:link href="http://www.ooso.net/category/javascript/feed" rel="self" type="application/rss+xml" />
	<link>http://www.ooso.net</link>
	<description>Linux + Apache + Mysql + Php + Flash</description>
	<lastBuildDate>Thu, 11 Mar 2010 17:54:31 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>gmail的pop3快速刷新脚本</title>
		<link>http://www.ooso.net/archives/526</link>
		<comments>http://www.ooso.net/archives/526#comments</comments>
		<pubDate>Fri, 30 Oct 2009 13:34:20 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[gmail]]></category>
		<category><![CDATA[greasemonkey]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=526</guid>
		<description><![CDATA[gmail接收pop3邮件的周期挺长的，如果邮件不是太频繁的话，差不多1小时才会刷新一次。如果你是firefox用户的话，解决办法是：


安装greasemonkey插件

				<span class="readmore"><a href="http://www.ooso.net/archives/526" title="gmail的pop3快速刷新脚本">阅读全文（242字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>gmail接收pop3邮件的周期挺长的，如果邮件不是太频繁的话，差不多1小时才会刷新一次。如果你是<a href="/?tag=firefox">firefox</a>用户的话，解决办法是：</p>
<ol>
<ul>
<li>安装<a href="/?tag=greasemonkey">greasemonkey</a>插件</li>
<li>安装<a href="http://userscripts.org/scripts/show/56812">猴子脚本 </a></li>
<li>安装<a href="http://customcode.googlecode.com/files/gmail_pop3_quick_checker.user.js">我改写过的邮件检查脚本</a></li>
</ul>
</ol>
<p>这个工具的用途是在页面上方的“刷新”旁边新增一个链接“刷新POP3邮件”，点击之后会马上检查所有的POP3邮箱。至于自动刷新功能，还等着看官你自己搞定呢。</p>
<p>BTW:如果是英文版的gmail，请手工修改gmail_pop3_quick_checker.user.js，我都提取出来了。 </p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/526/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Yahoo yui host提供combo handler服务</title>
		<link>http://www.ooso.net/archives/458</link>
		<comments>http://www.ooso.net/archives/458#comments</comments>
		<pubDate>Thu, 17 Jul 2008 01:42:45 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[yahoo]]></category>
		<category><![CDATA[yui]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/458</guid>
		<description><![CDATA[Yahoo之前提供了公开的YUI Hosting，现在又在这个基础上进一步提供了combo handler服务。这项服务的目的是尽可能减少http请求的数目，以提高web前端的展现速度，这也是高性能网页开发的14条军规之首。
此前，如果要使用YUI Rich Text Editor，需要引用若干外部js。共计6个http请求。
PLAIN TEXT
CODE:

				<span class="readmore"><a href="http://www.ooso.net/archives/458" title="Yahoo yui host提供combo handler服务">阅读全文（252字）</a></span>]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.ooso.net/index.php/archives/265">Yahoo之前提供了公开的YUI Hosting</a>，现在又在这个基础上进一步提供了combo handler服务。这项服务的目的是尽可能减少http请求的数目，以提高web前端的展现速度，这也是<a href="http://www.space007.com/post/129.html">高性能网页开发的14条军规</a>之首。</p>
<p>此前，如果要使用YUI Rich Text Editor，需要引用若干外部js。共计6个http请求。</p>
<div class="igBar"><span id="lcode-3"><a href="#" onclick="javascript:showCodeTxt('code-3'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-3">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;src=<span style="color:#CC0000;">"http://yui.yahooapis.com/2.5.2/build/yahoo-dom-event/yahoo-dom-event.js"</span>&gt;&lt;/script&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;src=<span style="color:#CC0000;">"http://yui.yahooapis.com/2.5.2/build/container/container_core-min.js"</span>&gt;&lt;/script&gt; </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;src=<span style="color:#CC0000;">"http://yui.yahooapis.com/2.5.2/build/menu/menu-min.js"</span>&gt;&lt;/script&gt; </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;src=<span style="color:#CC0000;">"http://yui.yahooapis.com/2.5.2/build/element/element-beta-min.js"</span>&gt;&lt;/script&gt; </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;src=<span style="color:#CC0000;">"http://yui.yahooapis.com/2.5.2/build/button/button-min.js"</span>&gt;&lt;/script&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;src=<span style="color:#CC0000;">"http://yui.yahooapis.com/2.5.2/build/editor/editor-beta-min.js"</span>&gt;&lt;/script&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p> </p>
<p>如果使用combo handler，那么http请求数可以合并成一个，如下：   </p>
<div class="igBar"><span id="lcode-4"><a href="#" onclick="javascript:showCodeTxt('code-4'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-4">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">src=<span style="color:#CC0000;">"http://yui.yahooapis.com/combo?2.5.2/build/yahoo-dom-event/yahoo-dom-event.js&amp;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#CC0000;">2.5.2/build/container/container_core-min.js&amp;2.5.2/build/menu/menu-min.js&amp;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#CC0000;">2.5.2/build/element/element-beta-min.js&amp;2.5.2/build/button/button-min.js&amp;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#CC0000;">2.5.2/build/editor/editor-beta-min.js"</span>&gt;&lt;/script&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>可惜这个host在国外，对国内的yui用户来说，没有什么帮助。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/458/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>图片预加载效果的实现</title>
		<link>http://www.ooso.net/archives/423</link>
		<comments>http://www.ooso.net/archives/423#comments</comments>
		<pubDate>Sun, 15 Jun 2008 23:25:48 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[ajax]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[picasa]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=423</guid>
		<description><![CDATA[使用picasa的时候，注意到它首先是显示模糊的图片，然后图片突然变得清晰，这样做有一定的好处——picasa的图片翻页是用javascript实现的，如果直接载入大图，中间势必会有个空档，用户在这中间会感觉很空虚~~
于是我花了点时间，打探它的实现方式，发觉很简单，不是用的lowsrc之类的标记，而是简单的js。
代码示例
PLAIN TEXT

				<span class="readmore"><a href="http://www.ooso.net/archives/423" title="图片预加载效果的实现">阅读全文（363字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>使用<a href="http://www.picasaweb.com">picasa</a>的时候，注意到它首先是显示模糊的图片，然后图片突然变得清晰，这样做有一定的好处——picasa的图片翻页是用<a href="/?tag=javascript">javascript</a>实现的，如果直接载入大图，中间势必会有个空档，用户在这中间会感觉很空虚~~</p>
<p>于是我花了点时间，打探它的实现方式，发觉很简单，不是用的lowsrc之类的标记，而是简单的js。</p>
<h3>代码示例</h3>
<div class="igBar"><span id="lcode-6"><a href="#" onclick="javascript:showCodeTxt('code-6'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-6">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;img id=<span style="color:#CC0000;">"myImage"</span> src=<span style="color:#CC0000;">"small_144.jpg"</span> width=<span style="color:#CC0000;">"640"</span> /&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var img = new Image<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">img.<span style="">src</span> = <span style="color:#CC0000;">"http://imghost/big_640_480.jpg"</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">img.<span style="">onload</span> = function<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; document.<span style="">getElementById</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'myImage'</span><span style="color:#006600; font-weight:bold;">&#41;</span>.<span style="">src</span> = this.<span style="">src</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#125;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>如此这般，待大图载入完成之后，利用js替换原小图的src，就完成了图片预加载效果。关键点是图片的onload事件利用。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/423/feed</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Google AJAX Feed API的冷门用法</title>
		<link>http://www.ooso.net/archives/422</link>
		<comments>http://www.ooso.net/archives/422#comments</comments>
		<pubDate>Sat, 14 Jun 2008 03:14:28 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[google]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[json]]></category>
		<category><![CDATA[rss]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/422</guid>
		<description><![CDATA[Google AJAX Feed API是google提供的一个很实用的API，我经常用它来跨域获取某些rss feed并展现。但是使用前需要申请一个API KEY，然后才可以在指定网站上使用，如果有多级子域名的话，挨个申请key是一个很烦人的事情，所以也就有了下面说的冷门用法。
Google AJAX Feed API提供了针对Flash或javascript无效这两种环境的额外接口，其中一种可以支持jsonp方式调用，跨域调用feed就全靠它了。
jsonp调用代码示例
PLAIN TEXT

				<span class="readmore"><a href="http://www.ooso.net/archives/422" title="Google AJAX Feed API的冷门用法">阅读全文（364字）</a></span>]]></description>
			<content:encoded><![CDATA[<p><a href="http://code.google.com/apis/ajaxfeeds">Google AJAX Feed API</a>是google提供的一个很实用的API，我经常用它来跨域获取某些rss feed并展现。但是使用前需要申请一个API KEY，然后才可以在指定网站上使用，如果有多级子域名的话，挨个申请key是一个很烦人的事情，所以也就有了下面说的冷门用法。</p>
<p>Google AJAX Feed API提供了针对Flash或javascript无效这两种环境的额外接口，其中一种可以支持jsonp方式调用，跨域调用feed就全靠它了。</p>
<h3>jsonp调用代码示例</h3>
<div class="igBar"><span id="lcode-8"><a href="#" onclick="javascript:showCodeTxt('code-8'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-8">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">function foo<span style="color:#006600; font-weight:bold;">&#40;</span>rss<span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; console.<span style="">log</span><span style="color:#006600; font-weight:bold;">&#40;</span>rss<span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;/script&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script src=<span style="color:#CC0000;">"http://ajax.googleapis.com/ajax/services/feed/load?q=http%3A%2F%2Ffeed.ooso.net&amp;v=1.0&amp;callback=foo"</span>&gt;&lt;/script&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>这段代码中，指定了callback function为<b>foo</b>，所以我预先定义了一个function foo，运行时就可以在<a href="/?tag=firebug">firebug</a>的控制台里清楚的看到返回的json串结构。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/422/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>jQuerify书签</title>
		<link>http://www.ooso.net/archives/417</link>
		<comments>http://www.ooso.net/archives/417#comments</comments>
		<pubDate>Tue, 10 Jun 2008 00:35:19 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[jquery]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=417</guid>
		<description><![CDATA[我不知道有多少人在使用浏览器的书签，这东东有时候实在是很有用的，比如现在说到的jQuerify书签。
jQuerify书签的功能很简单，那就是在当前页面中直接载入jquery.js，并以一个粉红色的浮动层提示jquery已经载入。书签的源代码如下：
PLAIN TEXT
CODE:

				<span class="readmore"><a href="http://www.ooso.net/archives/417" title="jQuerify书签">阅读全文（1057字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>我不知道有多少人在使用浏览器的书签，这东东有时候实在是很有用的，比如现在说到的<a href="http://www.learningjquery.com/2008/06/updated-jquery-bookmarklet">jQuerify书签</a>。</p>
<p>jQuerify书签的功能很简单，那就是在当前页面中直接载入<a href="/?tag=jquery">jquery.js</a>，并以一个粉红色的浮动层提示jquery已经载入。书签的源代码如下：</p>
<div class="igBar"><span id="lcode-11"><a href="#" onclick="javascript:showCodeTxt('code-11'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-11">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var s=document.<span style="">createElement</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'script'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">s.<span style="">setAttribute</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'src'</span>,<span style="color:#CC0000;">'http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">if<span style="color:#006600; font-weight:bold;">&#40;</span>typeof jQuery!=<span style="color:#CC0000;">'undefined'</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; var msg=<span style="color:#CC0000;">'This page was already jQuerified'</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#125;</span> else <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; document.<span style="">getElementsByTagName</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'head'</span><span style="color:#006600; font-weight:bold;">&#41;</span><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#93;</span>.<span style="">appendChild</span><span style="color:#006600; font-weight:bold;">&#40;</span>s<span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; var msg=<span style="color:#CC0000;">'This page is now jQuerified'</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var el=document.<span style="">createElement</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'div'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; el.<span style="">style</span>.<span style="">position</span>=<span style="color:#CC0000;">'fixed'</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; el.<span style="">style</span>.<span style="">height</span>=<span style="color:#CC0000;">'30'</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; el.<span style="">style</span>.<span style="">width</span>=<span style="color:#CC0000;">'200'</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; el.<span style="">style</span>.<span style="">margin</span>=<span style="color:#CC0000;">'0 auto 0 auto'</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; el.<span style="">id</span>=<span style="color:#CC0000;">'jq-kswedberg'</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; el.<span style="">style</span>.<span style="">top</span>=<span style="color:#CC0000;">'0'</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; el.<span style="">style</span>.<span style="">left</span>=<span style="color:#CC0000;">'40%'</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; el.<span style="">style</span>.<span style="">padding</span>=<span style="color:#CC0000;">'5px 10px 5px 10px'</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; el.<span style="">style</span>.<span style="">backgroundColor</span>=<span style="color:#CC0000;">'#f99'</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; el.<span style="">innerHTML</span>=msg;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var b=document.<span style="">getElementsByTagName</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'body'</span><span style="color:#006600; font-weight:bold;">&#41;</span><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#93;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">b.<span style="">appendChild</span><span style="color:#006600; font-weight:bold;">&#40;</span>el<span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">window.<span style="">setTimeout</span><span style="color:#006600; font-weight:bold;">&#40;</span>function<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; jQuery<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'#jq-kswedberg'</span><span style="color:#006600; font-weight:bold;">&#41;</span>.<span style="">fadeOut</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'slow'</span>,function<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; jQuery<span style="color:#006600; font-weight:bold;">&#40;</span>this<span style="color:#006600; font-weight:bold;">&#41;</span>.<span style="">remove</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#125;</span>, <span style="color:#800000;color:#800000;">2500</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">void<span style="color:#006600; font-weight:bold;">&#40;</span>s<span style="color:#006600; font-weight:bold;">&#41;</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>书签的链接在下边，如果是firefox的话，可以直接拖拽到firefox的书签栏上。</p>
<p>» <a href="javascript:var%20s=document.createElement('script');s.setAttribute('src','http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js');if(typeof%20jQuery!='undefined'){var%20msg='This%20page%20was%20already%20jQuerified'}else{document.getElementsByTagName('head')[0].appendChild(s);var%20msg='This%20page%20is%20now%20jQuerified'}var%20el=document.createElement('div');el.style.position='fixed';el.style.height='30';el.style.width='200';el.style.margin='0%20auto%200%20auto';el.id='jq-kswedberg';el.style.top='0';el.style.left='40%';el.style.padding='5px%2010px%205px%2010px';el.style.backgroundColor='#f99';el.innerHTML=msg;var%20b=document.getElementsByTagName('body')[0];b.appendChild(el);window.setTimeout(function()%20{jQuery('#jq-kswedberg').fadeOut('slow',function(){jQuery(this).remove()});},2500);void(s);">jQuerify</a> «</p>
<p>这里用到了<a href="http://www.ooso.net/index.php/archives/404">最近说到的google cdn</a>，速度可是足够快的。在使用书签之后，就可以尽情享受jquery的便利了，比如在firebug的console输入：</p>
<div class="igBar"><span id="lcode-12"><a href="#" onclick="javascript:showCodeTxt('code-12'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-12">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">$<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'body'</span><span style="color:#006600; font-weight:bold;">&#41;</span>.<span style="">background</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'#ffc'</span><span style="color:#006600; font-weight:bold;">&#41;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>你会看到屏幕的背景色变黄了:)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/417/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>jQuery UI 1.5</title>
		<link>http://www.ooso.net/archives/419</link>
		<comments>http://www.ooso.net/archives/419#comments</comments>
		<pubDate>Mon, 09 Jun 2008 10:55:09 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=419</guid>
		<description><![CDATA[jQuery UI 1.5正式版发布，仍然保持了jquery简单易用的特点。
简化的API调用
这个版本最大的改进是重新定义了API规则，之前API提供的95%以上的方法都移除了，取而代之的是更简单的调用规则，每个plugin只保留了一个方法，以draggable为例：


				<span class="readmore"><a href="http://www.ooso.net/archives/419" title="jQuery UI 1.5">阅读全文（503字）</a></span>]]></description>
			<content:encoded><![CDATA[<p><a href="http://ui.jquery.com">jQuery UI 1.5正式版发布</a>，仍然保持了jquery简单易用的特点。</p>
<h3>简化的API调用</h3>
<p>这个版本最大的改进是重新定义了API规则，之前API提供的95%以上的方法都移除了，取而代之的是更简单的调用规则，每个plugin只保留了一个方法，以draggable为例：</p>
<ul>
<li>$(”div”).draggable() 创建一个拖拽对象</li>
<li>$(”div”).draggable(”destroy”) 删掉拖拽对象</li>
<li>$(”div”).draggable(”method”) 呼叫这个plugin的其它方法</li>
</ul>
<h3>jQuery UI的另外一个杀手级应用——ThemeRoller</h3>
<p><a href="http://ui.jquery.com/themeroller"><img src="http://jquery.com/blog/wp-content/uploads/2008/06/themeRoller_ui_full.png" alt="ThemeRoller" /></a></p>
<p>利用ThemeRoller，你只要几分钟就可以创建一个自己的主题，可以方便调整色彩并预览效果，在调整满意之后，还能将主题的图片和css以zip包下载，算是相当贴心的一个功能，只可惜从国内访问过去速度有些抱歉。</p>
<p><a href="/?tag=jquery">jQuery</a> UI 1.5的整个包包大小是1.78M，相比yui来说是有过之而无不及。好在包内的各个demo都是真材实料，相当精彩，大一点也无妨。</p>
<p>更详细的信息请看：<a href="http://jquery.com/blog/2008/06/09/jquery-ui-v15-released-focus-on-consistent-api-and-effects/">jQuery UI v1.5 Released, Focus on Consistent API and Effects</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/419/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>我也试用YUI Uploader</title>
		<link>http://www.ooso.net/archives/405</link>
		<comments>http://www.ooso.net/archives/405#comments</comments>
		<pubDate>Fri, 30 May 2008 01:58:11 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[flash]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[yui]]></category>
		<category><![CDATA[上传]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/405</guid>
		<description><![CDATA[早就知道YUI里面有Uploader这么一个上传组件，可以按住ctrl多选文件上传(就像flickr那样的上传)，并且可以支持进度条，这样对用户来说是相当方便的。
由于YUI Uploader是利用javascript + flash实现的，所以用户的浏览器上只要有flash player就可以使用，也不需要额外安装别的插件了，这显然也是YUI Uploader的一大优势。
我的YUI Uploader试用之旅


				<span class="readmore"><a href="http://www.ooso.net/archives/405" title="我也试用YUI Uploader">阅读全文（1139字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>早就知道<a href="http://developer.yahoo.com/yui/">YUI</a>里面有Uploader这么一个上传组件，可以按住ctrl多选文件上传(就像flickr那样的上传)，并且可以支持进度条，这样对用户来说是相当方便的。</p>
<p>由于YUI Uploader是利用javascript + <a href="/?tag=flash">flash</a>实现的，所以用户的浏览器上只要有flash player就可以使用，也不需要额外安装别的插件了，这显然也是YUI Uploader的一大优势。</p>
<h3>我的YUI Uploader试用之旅</h3>
<ul>
<li>首先<a href="http://developer.yahoo.com/yui/examples/uploader/assets/uploader-advanced.zip">下载Uploader批量上传页的html源文件</a></li>
<li>解压后放置在你的web服务器上，比如我就是在自己的台式机上安装了一个xampp</li>
<li>现在需要一个处理上传操作的后端程序，在这里我是用php简单的写了一个，如果你用别的语言也是不成问题的。在<b>uploader-advanced-source.html</b>的同一目录下放置<b>upload.php</b>，源文件如下：
<div class="igBar"><span id="lphp-14"><a href="#" onclick="javascript:showCodeTxt('php-14'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">PHP:</span>
<div id="php-14">
<div class="php">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#616100;">foreach</span> <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#0000FF;">$_FILES</span> <span style="color:#616100;">as</span> <span style="color:#0000FF;">$fieldName</span> =&gt; <span style="color:#0000FF;">$file</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span> </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#0000FF;">$name</span> = <span style="color:#000066;">md5</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#000066;">microtime</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#000066;">move_uploaded_file</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#0000FF;">$file</span><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#FF0000;">'tmp_name'</span><span style="color:#006600; font-weight:bold;">&#93;</span>, <span style="color:#FF0000;">"./"</span> . <span style="color:#0000FF;">$name</span> . <span style="color:#FF0000;">'.jpg'</span><span style="color:#006600; font-weight:bold;">&#41;</span>; </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#000066;">echo</span> <span style="color:#0000FF;">$fieldName</span> . <span style="color:#FF0000;">' uploaded!'</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#125;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></li>
<li>下载http://yui.yahooapis.com/2.5.1/build/uploader/assets/uploader.swf，然后把<b>uploader.swf</b>放在和<b>upload.php</b>的同一目录下，这是为了避免javascript和flash交互过程中出现跨域问题。</li>
<li>修改uploader-advanced-source.html
<ul>
<li>把"YOUR UPLOAD URL GOES HERE"替换成你的upload.php所在的url，比如我的就是http://localhost/yui/upload.php
<li>把YAHOO.widget.Uploader.SWFURL修改成你的uploader.swf实际url</li>
</ul>
</li>
<li>现在访问uploader-advanced-source.html，试试批量上传功能吧</li>
</ul>
<h3>试用的一点补充</h3>
<ul>
<li>这个例子里面的php源文件只是考虑上传n张jpg文件的情况，可根据实际情况调整。</li>
<li>上传后的文件名是md5随机加密的，在upload.php同一目录可见</li>
<li>由于flash的bug，运行在windows下的firefox无法正确获得flash传递过来的cookie，如果上传应用对cookie有依赖，可能会需要做额外的处理。</li>
<li><del>为了能够确切的显示上传进度条，可能需要php 5.2的<a href="http://pecl.php.net/package/APC">apc</a>扩展支持</del></li>
<li>上传进度由flash完成</li>
<li>YUI 2.5.2已经附上uploader.swf的actionscript，有一定的学习价值</li>
</ul>
<h3>贴一张Uploader使用效果图</h3>
<p><img src="http://developer.yahoo.com/yui/examples/uploader/assets/uploader-advanced.jpg" /></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/405/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>利用Google Ajax Library API加速常用js类库的载入</title>
		<link>http://www.ooso.net/archives/404</link>
		<comments>http://www.ooso.net/archives/404#comments</comments>
		<pubDate>Wed, 28 May 2008 06:56:58 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[ajax]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/404</guid>
		<description><![CDATA[google前不久推出了Google Ajax Library API，说白了就是提供几个知名js库的host，目前有:

jQuery
prototype

				<span class="readmore"><a href="http://www.ooso.net/archives/404" title="利用Google Ajax Library API加速常用js类库的载入">阅读全文（523字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>google前不久推出了<a href="http://googleajaxsearchapi.blogspot.com/2008/05/speed-up-access-to-your-favorite.html">Google Ajax Library API</a>，说白了就是提供几个知名js库的host，目前有:</p>
<ul>
<li><a href="http://code.google.com/apis/ajaxlibs/documentation/index.html#jquery">jQuery</a></li>
<li><a href="http://code.google.com/apis/ajaxlibs/documentation/index.html#prototype">prototype</a></li>
<li><a href="http://code.google.com/apis/ajaxlibs/documentation/index.html#script_aculo_us">script.aculo.us</a></li>
<li><a href="http://code.google.com/apis/ajaxlibs/documentation/index.html#mootools">MooTools</a></li>
<li><a href="http://code.google.com/apis/ajaxlibs/documentation/index.html#dojo">dojo</a></li>
</ul>
<p><a href="/?tag=google">google</a>提供的这批js类库都有使用cdn，同时提供压缩和非压缩版本，并gzip输出。比如Prototype在未压缩前是124k，压缩后则只有30k，而jquery经过瘦身以后，也是从97k降到了16k。</p>
<p>这项服务的意义在于，如果各个网站都使用google提供的某个js类库比如jquery，那么由于浏览器缓存的缘故，用户就可以避免下载相同内容的js，这样也就能提高js的载入速度了。</p>
<h2>google ajax library api使用方法</h2>
<p><b>传统方式</b></p>
<div class="igBar"><span id="lcode-17"><a href="#" onclick="javascript:showCodeTxt('code-17'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-17">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script src=<span style="color:#CC0000;">"http://ajax.googleapis.com/ajax/libs/prototype/1.6.0.2/prototype.js"</span>&gt;&lt;/script&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p><b>使用google.load载入</b></p>
<div class="igBar"><span id="lcode-18"><a href="#" onclick="javascript:showCodeTxt('code-18'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-18">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script src=<span style="color:#CC0000;">"http://www.google.com/jsapi"</span>&gt;&lt;/script&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#FF9933; font-style:italic;">// Load jQuery</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">google.<span style="">load</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">"jquery"</span>, <span style="color:#CC0000;">"1"</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;/script&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>下面是一段小小的视频用来解释它的工作原理:<br />
<object width="425" height="355"><param name="movie" value="http://www.youtube.com/v/4F4Jb1ssEvI&#038;hl=en"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/4F4Jb1ssEvI&#038;hl=en" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"></embed></object></p>
<h2>Update</h2>
<p>昨天在某个小页面上尝试引入google提供的jquery.min.js，结果让我大失所望，虽然有时候访问速度很快，但是偶尔能刷出22秒以上的响应时间，如果是这样不稳定的话，那么实在是不敢放心使用。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/404/feed</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>wordpress plugin &#8211; search engine related posts</title>
		<link>http://www.ooso.net/archives/392</link>
		<comments>http://www.ooso.net/archives/392#comments</comments>
		<pubDate>Fri, 02 May 2008 05:42:00 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[google]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[plugin]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=392</guid>
		<description><![CDATA[Table of content

Description
Usage

				<span class="readmore"><a href="http://www.ooso.net/archives/392" title="wordpress plugin &#8211; search engine related posts">阅读全文（854字）</a></span>]]></description>
			<content:encoded><![CDATA[<h3>Table of content</h3>
<ul>
<li><a href="#Description">Description</a></li>
<li><a href="#Usage">Usage</a></li>
<li><a href="#Download">Download</a></li>
<li><a href="#History">History</a></li>
<li><a href="#Link">Link</a></li>
</ul>
<h3>Description</h3>
<p><b>English version</b></p>
<p>When someone is referred from a search engine like Google, the plugin show your blog content matched the terms they search for.</p>
<p><b>中文说明</b></p>
<p>当用户从google搜索到你的博客上，这个wordpress <a href="/?tag=plugin">插件</a>会根据用户搜索的关键词显示你的博客上更多的相关内容。目前也只对google生效，下一个版本将对baidu生效。</p>
<p>这个插件完全使用javascript加上google的api完成，不需要占用服务器端的资源，环保且安全。</p>
<h3 id="Usage">Usage</h3>
<p><b>English version:</b></p>
<ul>
<li>unzip it</li>
<li>Put <b>&lt;div style="display:none" id="search_content"&gt;&lt;/div&gt;</b> at the place in your template where you want the list of related posts</li>
<li>Copy search_related_posts.php to direcotry wp-contents/plugin and activate the plugin.</li>
<li>done!</li>
</ul>
<p><b>中文说明:</b></p>
<ul>
<li>解压</li>
<li>在wordpress模板中添加一个id为search_content的html标签，比如
<div class="igBar"><span id="lcode-20"><a href="#" onclick="javascript:showCodeTxt('code-20'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-20">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;div id=<span style="color:#CC0000;">"search_content"</span> style=<span style="color:#CC0000;">"display:none;"</span>&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;h1&gt;相关搜索结果&lt;/h1&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;/div&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></li>
<li>复制search_related_posts.php到wp-contents/plugin目录，并激活插件.</li>
<li>done! 现在你可以试着从google搜索上先搜到自己的博客，然后点击进去看看插件的效果。</li>
</ul>
<h3 id="Download">Download</h3>
<p><a href="http://wordpress.org/extend/plugins/search-engine-related-posts/">latest search engine related posts</a></p>
<h3 id="History">History</h3>
<ul>
<li><a href="http://www.ooso.net/index.php/archives/516">search engine related posts 1.2</a></li>
<li><a href="http://www.ooso.net/index.php/archives/392">search engine related posts 1.0</a></li>
</ul>
<h3 id="Link">Link</h3>
<ul>
<li><a href="http://wordpress.org/extend/plugins/search-engine-related-posts/">search engine related posts at wordpress.org</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/392/feed</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
		<item>
		<title>AIR入门者推荐阅读 &#8212; AIR for JavaScript Developers</title>
		<link>http://www.ooso.net/archives/390</link>
		<comments>http://www.ooso.net/archives/390#comments</comments>
		<pubDate>Sat, 26 Apr 2008 03:36:24 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[air]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/390</guid>
		<description><![CDATA[O'reilly的电子书 AIR for JavaScript 更新了。可以在这里免费下载。
这本书按照 创造共用方式授权，这意味着你不仅仅可以合法的免费下载，还可以按照自己的意愿做些修改。我翻看了一些章节，这本书对于AIR的html + js开发者来说，是一本很好的入门教程。这次更新的内容还包括AIR的安全模型介绍。
]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.insideria.com/assets_c/2008/04/airbookcover-thumb-100x165.png" align="left" /><a href="http://onair.adobe.com/blogs/onair/2008/04/17/adobe-air-for-javascript-developers-pocketguide-now-available/">O'reilly的电子书 AIR for JavaScript 更新</a>了。可以<a href="http://www.insideria.com/upload/2008/04/weekend_reading/AIRforJSDevPocketGuide.pdf">在这里免费下载</a>。</p>
<p>这本书按照 <a href="http://creativecommons.org/licenses/by-nc-sa/3.0/">创造共用方式授权</a>，这意味着你不仅仅可以合法的免费下载，还可以按照自己的意愿做些修改。我翻看了一些章节，这本书对于AIR的html + js开发者来说，是一本很好的入门教程。这次更新的内容还包括<a href="/?tag=air">AIR</a>的安全模型介绍。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/390/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Adobe AIR教程for HTML/JAVASCRIPT开发者</title>
		<link>http://www.ooso.net/archives/354</link>
		<comments>http://www.ooso.net/archives/354#comments</comments>
		<pubDate>Mon, 24 Mar 2008 00:52:15 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[adobe]]></category>
		<category><![CDATA[air]]></category>
		<category><![CDATA[dreamweaver]]></category>
		<category><![CDATA[html]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=354</guid>
		<description><![CDATA[最近不是太有空，加上泡网络时间太长，对新鲜事物的敏感度有所下降。因此当Adobe出了个AIR，我还是兴趣缺缺，没功夫去试用。
但是兴趣这玩意可能也有些生理周期，前几天突然来了神把这个AIR好好端详一番，却发觉网上暂时没有适合我这种初级新手看的AIR教程，鼓捣了几天，仍然是毫无进展，我甚至连个hello world之类的简单air package都打不出来。也许小时候特意去踩过狗屎，因此现在我又走上狗屎运，在即将放弃的前一刻找到了一篇比较细致的AIR教程，记录下来，好记性不如烂键盘。
俺目前的情况是，没有安装Dreamweaver，Flash之类的软件，只用一些免费软件，所以我只打算写html/javascript之类的代码，flash方面的暂时不涉及，另外adobe提供的dreamweaver air sdk也是用不上，可谓一穷二白。

				<span class="readmore"><a href="http://www.ooso.net/archives/354" title="Adobe AIR教程for HTML/JAVASCRIPT开发者">阅读全文（1703字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>最近不是太有空，加上泡网络时间太长，对新鲜事物的敏感度有所下降。因此当Adobe出了个<a href="/index.php?tag=air">AIR</a>，我还是兴趣缺缺，没功夫去试用。</p>
<p>但是兴趣这玩意可能也有些生理周期，前几天突然来了神把这个AIR好好端详一番，却发觉网上暂时没有适合我这种初级新手看的AIR教程，鼓捣了几天，仍然是毫无进展，我甚至连个hello world之类的简单air package都打不出来。也许小时候特意去踩过狗屎，因此现在我又走上狗屎运，在即将放弃的前一刻找到了一篇比较细致的AIR教程，记录下来，好记性不如烂键盘。</p>
<p>俺目前的情况是，没有安装Dreamweaver，Flash之类的软件，<a href="http://www.ooso.net/index.php/archives/178">只用一些免费软件</a>，所以我只打算写html/javascript之类的代码，flash方面的暂时不涉及，另外adobe提供的dreamweaver air sdk也是用不上，可谓一穷二白。</p>
<h3>第一步 -- 安装Adobe AIR和Adobe AIR SDK</h3>
<p>如果你还没装，可以<a href="http://www.adobe.com/go/air">去网站上下载Adobe AIR Runtime和Adobe AIR SDK</a>.</p>
<p>装完Adobe AIR SDK以后，为了方便，你还需要把它的bin目录添加到系统的path变量下，这样你可以直接运行它的打包和debug工具。</p>
<p><span id="more-354"></span></p>
<h3>第二步 -- 创建一些目录</h3>
<p>接下来创建一些目录来放置代码，比如：</p>
<blockquote><p>/appname/<br />
/appname/source/<br />
/appname/source/icons/<br />
/appname/build/
</p></blockquote>
<h3>第三步 -- 创建一个Application Descriptor</h3>
<p>AIR需要一个Application Descriptor来描述它的内容和属性，这是一个XML格式的文件。</p>
<p>它的文件名是<strong>application.xml</strong>，放置在<strong>/appname/source/</strong>目录。</p>
<div class="igBar"><span id="lxml-23"><a href="#" onclick="javascript:showCodeTxt('xml-23'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">XML:</span>
<div id="xml-23">
<div class="xml">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;application</span> <span style="color: #000066;">xmlns</span>=<span style="color: #ff0000;">"http://ns.adobe.com/air/application/1.0"</span><span style="font-weight: bold; color: black;">&gt;</span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;id<span style="font-weight: bold; color: black;">&gt;</span></span></span>com.example.appname <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/id<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;version<span style="font-weight: bold; color: black;">&gt;</span></span></span>1.0 <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/version<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;filename<span style="font-weight: bold; color: black;">&gt;</span></span></span>AppName <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/filename<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;initialWindow<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;content<span style="font-weight: bold; color: black;">&gt;</span></span></span>index.html <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/content<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;visible<span style="font-weight: bold; color: black;">&gt;</span></span></span>true <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/visible<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;width<span style="font-weight: bold; color: black;">&gt;</span></span></span>600<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/width<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;height<span style="font-weight: bold; color: black;">&gt;</span></span></span>600<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/height<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/initialWindow<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;icon<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;image16x16<span style="font-weight: bold; color: black;">&gt;</span></span></span>icons/appname-16.png<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/image16x16<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;image32x32<span style="font-weight: bold; color: black;">&gt;</span></span></span>icons/appname-32.png<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/image32x32<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;image48x48<span style="font-weight: bold; color: black;">&gt;</span></span></span>icons/appname-48.png<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/image48x48<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;image128x128<span style="font-weight: bold; color: black;">&gt;</span></span></span>icons/appname-128.png<span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/image128x128<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/icon<span style="font-weight: bold; color: black;">&gt;</span></span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;/application<span style="font-weight: bold; color: black;">&gt;</span></span></span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>这个xml文件很有些复杂，也很有一些历史，最可恶的是AIR beta1到后来的beta2乃至最后的1.0，从来就没统一过，变了又变，所以我在网上找到的一些教程都失效了，只能针对早期的beta版使用。</p>
<p>关于它的详细内容，可以参考模板，在adobe sdk安装目录下的<strong>templates/descriptor-template.xml</strong>.</p>
<h3>第四步 -- 创建你的应用</h3>
<p>下一步，创建一个index.html.</p>
<div class="igBar"><span id="lhtml-24"><a href="#" onclick="javascript:showCodeTxt('html-24'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">HTML:</span>
<div id="html-24">
<div class="html">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;html&gt;</span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;head&gt;</span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;title&gt;</span></span>My Window Title<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/title&gt;</span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/head&gt;</span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;body&gt;</span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;h1&gt;</span></span>Hello World<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/h1&gt;</span></span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/body&gt;</span></span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/html&gt;</span></span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>如果需要添加css,javascript以及图片，可以在/appname/source/下创建子目录放进去，就像平常写web应用那样。</p>
<h3>第五步 -- 测试你的应用</h3>
<p>如果你已经配置好了path环境变量（见第一步,需要重启电脑），下面很简单，首先打开一个命令行窗口，进入/appname/source/目录，然后运行：</p>
<blockquote><p>adl application.xml</p></blockquote>
<p>一切顺利的话，你的应用应该已经跑起来了，一个弹出的AIR应用窗口好不容易的展示它的第一次。</p>
<h3>第六步 -- 打包你的AIR应用</h3>
<p>在很多磕磕碰碰，反复调试之后，你可能已经完成了应用，现在你准备向朋友或者网上的菜鸟炫耀一下你的处女作。那么我们开始打包，这一步其实比我想象的要简单。</p>
<p>首先需要生成一个签名Certificate，并放置在应用的根目录<strong>/appname/</strong></p>
<blockquote><p>adt -certificate -cn SelfSign -ou Dev -o "Example" -c US 2048-RSA cert.pfx 换成你的密码</p></blockquote>
<p>然后就是进入source目录打包：</p>
<blockquote><p>adt -package -storetype pkcs12 -keystore ../cert.pfx ../build/AirTest.air application.xml .</p></blockquote>
<p>不出意外的话，会当场生成一个<strong>AppName.air</strong>文件，你可以安装一下感受亲手做的第一个Air应用。</p>
<p>原文：<a href="http://www.petefreitag.com/item/667.cfm">Adobe AIR Tutorial for HTML / JavaScript Developers</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/354/feed</wfw:commentRss>
		<slash:comments>32</slash:comments>
		</item>
		<item>
		<title>JQUERY和YUI混用出现的问题</title>
		<link>http://www.ooso.net/archives/347</link>
		<comments>http://www.ooso.net/archives/347#comments</comments>
		<pubDate>Sat, 22 Mar 2008 03:06:30 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[yui]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=347</guid>
		<description><![CDATA[有道是一山不容二虎，其实我本不该把JQUERY和YUI夹杂在一块使用，虽然它们各有长短，结合使用的确能够相得益彰，但是暗地里还存着什么矛盾和冲突，这就不是随便刷新一下网页能够看出来的。
列一下最近碰到的问题，备忘。
混用时，YUI的Event在ie6下表现异常
下面代码中，没能在window.onload事件中弹出一个alert弹出窗口。

				<span class="readmore"><a href="http://www.ooso.net/archives/347" title="JQUERY和YUI混用出现的问题">阅读全文（368字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>有道是一山不容二虎，其实我本不该把<a href="/index.php?tag=jquery">JQUERY</a>和<a href="/index.php?tag=yui">YUI</a>夹杂在一块使用，虽然它们各有长短，结合使用的确能够相得益彰，但是暗地里还存着什么矛盾和冲突，这就不是随便刷新一下网页能够看出来的。</p>
<p>列一下最近碰到的问题，备忘。</p>
<h3>混用时，YUI的Event在ie6下表现异常</h3>
<p>下面代码中，没能在window.onload事件中弹出一个alert弹出窗口。</p>
<div class="igBar"><span id="lcode-27"><a href="#" onclick="javascript:showCodeTxt('code-27'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-27">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">YAHOO.<span style="">util</span>.<span style="">Event</span>.<span style="">on</span><span style="color:#006600; font-weight:bold;">&#40;</span>window, <span style="color:#CC0000;">'load'</span>, function<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span>alert<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'hello'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;<span style="color:#006600; font-weight:bold;">&#125;</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;/script&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>猜想是jQuery重写了window.onload事件引起冲突，解决办法，使用jQuery的event。</p>
<div class="igBar"><span id="lcode-28"><a href="#" onclick="javascript:showCodeTxt('code-28'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-28">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">jQuery.<span style="">event</span>.<span style="">add</span><span style="color:#006600; font-weight:bold;">&#40;</span>window, <span style="color:#CC0000;">"load"</span>, function<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span>alert<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'hello'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;<span style="color:#006600; font-weight:bold;">&#125;</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;/script&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/347/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>inline-js 0.4 —— wordpress plugin</title>
		<link>http://www.ooso.net/archives/379</link>
		<comments>http://www.ooso.net/archives/379#comments</comments>
		<pubDate>Mon, 10 Mar 2008 16:30:25 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[plugin]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/379</guid>
		<description><![CDATA[Inline-js plugin minor update. It now work fine with exec-php plugin.
Download
Inline-js 0.4
详细信息

				<span class="readmore"><a href="http://www.ooso.net/archives/379" title="inline-js 0.4 —— wordpress plugin">阅读全文（107字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>Inline-js plugin minor update. It now work fine with exec-php plugin.</p>
<h3>Download</h3>
<p><a href="http://customcode.googlecode.com/files/inline-js.latest.zip">Inline-js 0.4</a></p>
<h3>详细信息</h3>
<p><a href="http://www.ooso.net/index.php/inline-js">inline-js wordpress plugin</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/379/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>YUI 2.5.0发布</title>
		<link>http://www.ooso.net/archives/382</link>
		<comments>http://www.ooso.net/archives/382#comments</comments>
		<pubDate>Thu, 21 Feb 2008 07:02:46 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[yahoo]]></category>
		<category><![CDATA[yui]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/382</guid>
		<description><![CDATA[YUI 2.5.0发布。
2月20日，YUI Team发布了YUI的最新版本2.5.0。增加了6个全新的组件：Layout Manager, Uploader(结合Flash和Javascript的多文件上传引擎), Resize Utility, ImageCropper, Cookie Utility和ProfilerViewer Control。同时这一版还提升了DataTable Control的功能和Slider Control增加了双滑块功能。
这个版本中的Uploader以及ImageCropper应该是相当有用的控件

				<span class="readmore"><a href="http://www.ooso.net/archives/382" title="YUI 2.5.0发布">阅读全文（432字）</a></span>]]></description>
			<content:encoded><![CDATA[<p><a href="/?tag=yui">YUI</a> 2.5.0发布。</p>
<blockquote><p>2月20日，YUI Team发布了YUI的最新版本2.5.0。增加了6个全新的组件：Layout Manager, Uploader(结合Flash和Javascript的多文件上传引擎), Resize Utility, ImageCropper, Cookie Utility和ProfilerViewer Control。同时这一版还提升了DataTable Control的功能和Slider Control增加了双滑块功能。</p></blockquote>
<p>这个版本中的Uploader以及ImageCropper应该是相当有用的控件</p>
<ul>
<li>Uploader采用<a href="/?tag=javascript">javascript</a>和flash，不仅支持多文件上传，更可以直观的查看上传进度，以前虽然有类似的代码，但是组件化的代码显然通用性和可用性更好。</li>
<li>ImageCroper可用于制作图片切片，基于YUI的Dragdrop和Resize</li>
</ul>
<h3>与YUI 2.5.0相关的链接</h3>
<ul>
<li><a href="http://developer.yahoo.com/yui">http://developer.yahoo.com/yui</a></li>
<li><a href="http://www.yuiblog.cn/2008/02/21/47/">yuiblog.cn</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/382/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>用来看新浪新闻的greasemonkey脚本</title>
		<link>http://www.ooso.net/archives/302</link>
		<comments>http://www.ooso.net/archives/302#comments</comments>
		<pubDate>Mon, 18 Feb 2008 13:23:36 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[greasemonkey]]></category>
		<category><![CDATA[插件]]></category>
		<category><![CDATA[新浪]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/302</guid>
		<description><![CDATA[刚从灾区长沙回到北京，那段时间虽然是隔三岔五的停电停水，俺还没忘趁着来电爬到新浪上面看看近期新闻，也好对最近的形势有些了解。闲着无聊写了个greasemonkey脚本，把新浪的新闻页右边那块没营养的内容统统隐藏掉。
放出来给需要的同学下载。
安装这个脚本的步骤


				<span class="readmore"><a href="http://www.ooso.net/archives/302" title="用来看新浪新闻的greasemonkey脚本">阅读全文（248字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>刚从灾区长沙回到北京，那段时间虽然是隔三岔五的停电停水，俺还没忘趁着来电爬到新浪上面看看近期新闻，也好对最近的形势有些了解。闲着无聊写了个<a href="/index.php?tag=greasemonkey">greasemonkey</a>脚本，把新浪的新闻页右边那块没营养的内容统统隐藏掉。</p>
<p>放出来给需要的同学下载。</p>
<h3>安装这个脚本的步骤</h3>
<ul>
<li>首先你必须是使用<a href="/index.php?tag=firefox">firefox</a>浏览器</li>
<li><a href="https://addons.mozilla.org/zh-CN/firefox/addon/748">安装greasemonkey插件</a></li>
<li><a href="http://customcode.googlecode.com/files/NewsSina.user.js">下载俺的NewsSina greasemonkey脚本</a>，如果你已经安装好greasemonkey，点击前面的链接应该会弹出一个安装窗口</li>
<li>去新浪的新闻页上看看，右边的内容还有吗？</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/302/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>YUI中国本地版</title>
		<link>http://www.ooso.net/archives/370</link>
		<comments>http://www.ooso.net/archives/370#comments</comments>
		<pubDate>Sun, 20 Jan 2008 08:31:02 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[yahoo]]></category>
		<category><![CDATA[yui]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/370</guid>
		<description><![CDATA[去年yahoo提供了公开的yui主机，这样即便自己没有server也可以直接使用yui的便利。但是由于主机在国外，访问速度不是很理想。现在终于有了本地版的yui hosting，访问速度有大的飞跃。
2008年1月14日雅虎中国正式发布本地版的YUI 2.4.1，今后将与YUI保持同步更新。这对国内的YUI使用者来说绝对是一个好消息，本地版的YUI采用了本地CDN部署，对于国内用户来说访问速度更快(图一)，比较访问国际YUI主机的速度(图二)快了至少5倍以上。
使用firebug查看载入速度


				<span class="readmore"><a href="http://www.ooso.net/archives/370" title="YUI中国本地版">阅读全文（259字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>去年<a href="/index.php?tag=yahoo">yahoo</a>提供了公开的yui主机，这样即便自己没有server也可以直接使用yui的便利。但是由于主机在国外，访问速度不是很理想。现在终于有了本地版的yui hosting，访问速度有大的飞跃。</p>
<blockquote><p>2008年1月14日雅虎中国正式发布本地版的YUI 2.4.1，今后将与YUI保持同步更新。这对国内的YUI使用者来说绝对是一个好消息，本地版的YUI采用了本地CDN部署，对于国内用户来说访问速度更快(图一)，比较访问国际YUI主机的速度(图二)快了至少5倍以上。</p></blockquote>
<h2>使用<a href="/index.php?tag=firebug">firebug</a>查看载入速度</h2>
<p><img width="98%" src="http://www.yuiblog.cn/wp-content/uploads/2008/01/yui2_1_4_all_js_files.PNG" alt="cn yui host" /></p>
<p>原文：<a href="http://www.yuiblog.cn/2008/01/14/yui%e6%9c%ac%e5%9c%b0%e7%89%88%e5%8f%91%e5%b8%83/">YUI Blog China</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/370/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>YUI 2.3.0的Rich Text Editor</title>
		<link>http://www.ooso.net/archives/367</link>
		<comments>http://www.ooso.net/archives/367#comments</comments>
		<pubDate>Sun, 05 Aug 2007 00:05:56 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[yui]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/367</guid>
		<description><![CDATA[YUI 2.3.0正式发布了。这个版本新增了一些新的组件，其中最大的亮点是它的Rich Text Editor (beta)，样式见下图：


YUI Rich Text Editor的特点

				<span class="readmore"><a href="http://www.ooso.net/archives/367" title="YUI 2.3.0的Rich Text Editor">阅读全文（299字）</a></span>]]></description>
			<content:encoded><![CDATA[<p><a href="http://developer.yahoo.com/yui/">YUI</a> 2.3.0正式发布了。这个版本新增了一些新的组件，其中最大的亮点是它的Rich Text Editor (beta)，样式见下图：<br />
<img src='http://www.ooso.net/wp-content/uploads/2007/08/rte.gif' alt='YUI Rich Text Editor' /></p>
<ul>
<h1>YUI Rich Text Editor的特点</h1>
<li><a href="http://developer.yahoo.com/yui/articles/gbs/">标识为A级的浏览器</a>支持良好，跨浏览器也有很好的表现</li>
<li>扩充方便，可以添加你自己的button</li>
<li>从图片上看，这个编辑器还支持直接从flickr抓取图片——可惜flickr在国内已经被和谐...</li>
</ul>
<ul>
<h1>YUI 2.3.0另外新增的5个组件</h1>
<li>Base CSS</li>
<li>YUILoader Utility (beta)</li>
<li>ImageLoader Utility (experimental)</li>
<li>Color Picker Control (beta)</li>
<li>YUI Test Utility (beta)</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/367/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>javascript在ie和firefox下的一些差异</title>
		<link>http://www.ooso.net/archives/362</link>
		<comments>http://www.ooso.net/archives/362#comments</comments>
		<pubDate>Tue, 31 Jul 2007 00:40:30 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[ie]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/362</guid>
		<description><![CDATA[javascript在ie和firefox下,运行结果有一些差异。下面把最近碰到的情况做个记录，以后也会不断补充以备忘。

object操作
firefox:可支持

				<span class="readmore"><a href="http://www.ooso.net/archives/362" title="javascript在ie和firefox下的一些差异">阅读全文（486字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>javascript在ie和<a href="/index.php?tag=firefox">firefox</a>下,运行结果有一些差异。下面把最近碰到的情况做个记录，以后也会不断补充以备忘。</p>
<ul>
<h2>object操作</h2>
<li>firefox:可支持
<div class="igBar"><span id="lcode-36"><a href="#" onclick="javascript:showCodeTxt('code-36'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-36">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var obj = <span style="color:#006600; font-weight:bold;">&#123;</span> <span style="color:#CC0000;">'key'</span> : <span style="color:#CC0000;">'aaa'</span>, <span style="color:#006600; font-weight:bold;">&#125;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></li>
<li>ie:不支持
<div class="igBar"><span id="lcode-37"><a href="#" onclick="javascript:showCodeTxt('code-37'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-37">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var obj = <span style="color:#006600; font-weight:bold;">&#123;</span> <span style="color:#CC0000;">'key'</span> : <span style="color:#CC0000;">'aaa'</span>, <span style="color:#006600; font-weight:bold;">&#125;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p> 会报javascript错误,最后的"<strong>,</strong>"必须去掉</li>
<h2><a href="/index.php?tag=javascript">javascript</a>对select元素的option操作</h2>
<li>firefox:可直接设置
<div class="igBar"><span id="lcode-38"><a href="#" onclick="javascript:showCodeTxt('code-38'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-38">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">option.<span style="">text</span> = <span style="color:#CC0000;">'foooooooo'</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></li>
<li>ie:只能设置
<div class="igBar"><span id="lcode-39"><a href="#" onclick="javascript:showCodeTxt('code-39'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-39">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">option.<span style="">innerHTML</span> = <span style="color:#CC0000;">'fooooooo'</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></li>
<h2>删除一个select的option</h2>
<li>firefox:可以
<div class="igBar"><span id="lcode-40"><a href="#" onclick="javascript:showCodeTxt('code-40'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-40">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">select.<span style="">options</span>.<span style="">remove</span><span style="color:#006600; font-weight:bold;">&#40;</span>selectedIndex<span style="color:#006600; font-weight:bold;">&#41;</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></li>
<li>ie7:可以用
<div class="igBar"><span id="lcode-41"><a href="#" onclick="javascript:showCodeTxt('code-41'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-41">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">select.<span style="">options</span><span style="color:#006600; font-weight:bold;">&#91;</span>i<span style="color:#006600; font-weight:bold;">&#93;</span> = null; </div>
</li>
</ol>
</div>
</div>
</div>
<p></li>
<li>ie6:需要写
<div class="igBar"><span id="lcode-42"><a href="#" onclick="javascript:showCodeTxt('code-42'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-42">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">select.<span style="">options</span><span style="color:#006600; font-weight:bold;">&#91;</span>i<span style="color:#006600; font-weight:bold;">&#93;</span>.<span style="">outerHTML</span> = null; </div>
</li>
</ol>
</div>
</div>
</div>
<p></li>
</ul>
<p>真是万恶的浏览器。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/362/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>可以用button代替input type=&#8221;submit&#8221;吗</title>
		<link>http://www.ooso.net/archives/352</link>
		<comments>http://www.ooso.net/archives/352#comments</comments>
		<pubDate>Mon, 16 Jul 2007 23:37:24 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[html]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/352</guid>
		<description><![CDATA[在ie下，&#60;button&#62;标记恐怕还存在几个不大不小的问题。

在一个表单里，如果有一个以上"submit"类型的&#60;button&#62;标签存在，在表单被提交时，不管你点击哪个&#60;button&#62;，所有&#60;button&#62;的值都会被post/get。
&#60;button&#62;的缺省type属性被设置为"button"，但是在A级别浏览器下，应该设置为"submit"才对

				<span class="readmore"><a href="http://www.ooso.net/archives/352" title="可以用button代替input type=&#8221;submit&#8221;吗">阅读全文（404字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>在ie下，&lt;button&gt;标记恐怕还存在几个不大不小的问题。</p>
<ol>
<li>在一个表单里，如果有一个以上"submit"类型的&lt;button&gt;标签存在，在表单被提交时，不管你点击哪个&lt;button&gt;，所有&lt;button&gt;的值都会被post/get。</li>
<li>&lt;button&gt;的缺省type属性被设置为"button"，但是在A级别浏览器下，应该设置为"submit"才对</li>
<li>如果你用javascript去访问&lt;button&gt;的value属性，IE却返回了&lt;button&gt;的innerHTML属性，很让人恼火。 (可以使用"getAttributeNode"方法来避免.)</li>
</ol>
<p>例如，一段<a href="index.php?tag=html">HTML</a>:</p>
<div class="igBar"><span id="lcode-44"><a href="#" onclick="javascript:showCodeTxt('code-44'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-44">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;form&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;button type=<span style="color:#CC0000;">"submit"</span> value=<span style="color:#CC0000;">"1"</span> name=<span style="color:#CC0000;">"action-1"</span>&gt;text <span style="color:#800000;color:#800000;">1</span>&lt;/button&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;button type=<span style="color:#CC0000;">"submit"</span> value=<span style="color:#CC0000;">"2"</span> name=<span style="color:#CC0000;">"action-2"</span>&gt;text <span style="color:#800000;color:#800000;">2</span>&lt;/button&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;/form&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>在IE下，上面两个button的数据都会被提交。并且ie会提交这两个button的innerText而不是value。而其它浏览器仅仅提交你点击的那个button。</p>
<h1>以上，应该尽量避免使用button标记。</h1>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/352/feed</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>Ajax+PHP+YUI手工制作rss阅读器</title>
		<link>http://www.ooso.net/archives/307</link>
		<comments>http://www.ooso.net/archives/307#comments</comments>
		<pubDate>Thu, 05 Jul 2007 00:06:14 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[ajax]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[rss]]></category>
		<category><![CDATA[yui]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/307</guid>
		<description><![CDATA[上次俺的简陋练习作品Ajax+json小有心得，这次继续尝试利用Ajax+PHP+YUI手工制作rss阅读器。
写一点html来展示RSS的内容
PLAIN TEXT
CODE:

				<span class="readmore"><a href="http://www.ooso.net/archives/307" title="Ajax+PHP+YUI手工制作rss阅读器">阅读全文（736字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>上次俺的<a href="http://www.ooso.net/index.php/archives/160">简陋练习作品Ajax+json</a>小有心得，这次继续尝试利用Ajax+PHP+YUI手工制作rss阅读器。</p>
<h1>写一点html来展示RSS的内容</h1>
<div class="igBar"><span id="lcode-48"><a href="#" onclick="javascript:showCodeTxt('code-48'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-48">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;body&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;h1&gt;RSS阅读器&lt;/h1&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;div id=<span style="color:#CC0000;">"rss_bd"</span>&gt;内容待填补&lt;/div&gt;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;/body&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p>
<span id="more-307"></span></p>
<h1>利用<a href="http://developer.yahoo.com/yui/">YUI</a>的Connection manager来处理XHR</h1>
<p><a href="http://yahoo.cn">yahoo</a>已经提供了在线的YUI Hosting,直接引用:</p>
<div class="igBar"><span id="lcode-49"><a href="#" onclick="javascript:showCodeTxt('code-49'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-49">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span> src=<span style="color:#CC0000;">"http://yui.yahooapis.com/2.2.2/build/yahoo/yahoo-min.js"</span>&gt;&lt;/script&gt; </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span> src=<span style="color:#CC0000;">"http://yui.yahooapis.com/2.2.2/build/connection/connection-min.js"</span>&gt;&lt;/script&gt; </div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span>&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var sUrl = <span style="color:#CC0000;">'proxy.php'</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var callback =</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; success: function<span style="color:#006600; font-weight:bold;">&#40;</span>o<span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp;document.<span style="">getElementById</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'rss_bd'</span><span style="color:#006600; font-weight:bold;">&#41;</span>.<span style="">innerHTML</span> = o.<span style="">responseText</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span>,</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; failure: function<span style="color:#006600; font-weight:bold;">&#40;</span>o<span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span><span style="color:#008000;">/*failure handler code*/</span><span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var transaction = YAHOO.<span style="">util</span>.<span style="">Connect</span>.<span style="">asyncRequest</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'GET'</span>, sUrl, callback, null<span style="color:#006600; font-weight:bold;">&#41;</span>; </div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;/script&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>很困，这部分没写完整，下次来补齐。</p>
<h1>用php做一个proxy来避免跨站访问的问题</h1>
<p><strong>proxy的要点</strong><br />
一定要输出header，否则在解析的时候你可能会遇到莫名奇妙的问题。<br />
如果你的服务器不支持远程url open，可以考虑使用curl，比如说在dreamhost的主机上</p>
<div class="igBar"><span id="lcode-50"><a href="#" onclick="javascript:showCodeTxt('code-50'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-50">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;?php</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">$searchUrl = <span style="color:#CC0000;">'http://api.search.yahoo.com/ImageSearchService/V1/imageSearch?appid=YahooDemo&amp;results=4&amp;output=json&amp;query='</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">if<span style="color:#006600; font-weight:bold;">&#40;</span>!empty<span style="color:#006600; font-weight:bold;">&#40;</span>$_POST<span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#CC0000;">'query'</span><span style="color:#006600; font-weight:bold;">&#93;</span><span style="color:#006600; font-weight:bold;">&#41;</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;echo file_get_contents<span style="color:#006600; font-weight:bold;">&#40;</span>$searchUrl . $_POST<span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#CC0000;">'query'</span><span style="color:#006600; font-weight:bold;">&#93;</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">?&gt; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>到这里，一个简陋的RSS阅读器的雏形已经完备了。</p>
<h1>什么是ajax</h1>
<p>在百度知道上面搜索的答案，一本正经的告诉你：</p>
<blockquote><p>Ajax（Asynchronous JavaScript and XML）是结合了Java技术、XML以及JavaScript等编程技术，可以让开发人员构建基于Java技术的Web应用，并打破了使用页面重载的惯例。 </p></blockquote>
<p>看了后立马一口茶水做雾状均匀喷洒到本本的屏幕上，Ajax本身和java有嘛关系？</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/307/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>jquery和greasemonkey齐上阵</title>
		<link>http://www.ooso.net/archives/346</link>
		<comments>http://www.ooso.net/archives/346#comments</comments>
		<pubDate>Tue, 03 Jul 2007 22:27:01 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[greasemonkey]]></category>
		<category><![CDATA[jquery]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/346</guid>
		<description><![CDATA[jquery写起来真的很简单，连我这刚接触jquery不久的新人都能很快用它码出大段的javascript。唯一的坏处是代码里充斥了大量的$。既然写javascript如此简单，那么用jquery+greasemonkey插件同时干活怎么样呢？
这里是一段提醒jquery已经载入的脚本，为了避免和页面上原有的代码冲突，得运行$.noConflict().
PLAIN TEXT
CODE:

				<span class="readmore"><a href="http://www.ooso.net/archives/346" title="jquery和greasemonkey齐上阵">阅读全文（940字）</a></span>]]></description>
			<content:encoded><![CDATA[<p><a href="http://docs.jquery.com">jquery</a>写起来真的很简单，连我这刚接触<a href="index.php?tag=jquery">jquery</a>不久的新人都能很快用它码出大段的javascript。唯一的坏处是代码里充斥了大量的<strong>$</strong>。既然写javascript如此简单，那么用jquery+greasemonkey插件同时干活怎么样呢？</p>
<p>这里是一段提醒jquery已经载入的脚本，为了避免和页面上原有的代码冲突，得运行$.noConflict().</p>
<div class="igBar"><span id="lcode-54"><a href="#" onclick="javascript:showCodeTxt('code-54'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-54">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#FF9933; font-style:italic;">// All your GM code must be inside this function</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">function letsJQuery<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#FF9933; font-style:italic;">//make sure there is no conflict between jQuery and other libraries</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">$.<span style="">noConflict</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#FF9933; font-style:italic;">//notify that jQuery is running...</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; $<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'&lt;div&gt;jQuery is running!&lt;/div&gt;'</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; .<span style="">css</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#123;</span>padding: <span style="color:#CC0000;">'10px'</span>, background: <span style="color:#CC0000;">'#ffc'</span>, position: <span style="color:#CC0000;">'absolute'</span>,top: <span style="color:#CC0000;">'0'</span>, width: <span style="color:#CC0000;">'100%'</span><span style="color:#006600; font-weight:bold;">&#125;</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; .<span style="">prependTo</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'body'</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; .<span style="">fadeIn</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'fast'</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; .<span style="">animate</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#123;</span>opacity: <span style="color:#800000;color:#800000;">1</span>.<span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#125;</span>, <span style="color:#800000;color:#800000;">300</span><span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; .<span style="">fadeOut</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'fast'</span>, function<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp;&nbsp; &nbsp;$<span style="color:#006600; font-weight:bold;">&#40;</span>this<span style="color:#006600; font-weight:bold;">&#41;</span>.<span style="">remove</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#FF9933; font-style:italic;">//start custom jQuery scripting.</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#125;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>引入jquery.js只用简单的一行，感谢greasemonkey!</p>
<div class="igBar"><span id="lcode-55"><a href="#" onclick="javascript:showCodeTxt('code-55'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-55">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">GM_JQ.<span style="">src</span> = <span style="color:#CC0000;">'http://jquery.com/src/jquery-latest.js'</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<h3>载入jquery的脚本</h3>
<div class="igBar"><span id="lcode-56"><a href="#" onclick="javascript:showCodeTxt('code-56'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-56">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var GM_JQ = document.<span style="">createElement</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'script'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">GM_JQ.<span style="">src</span> = <span style="color:#CC0000;">'http://code.jquery.com/jquery-latest.js'</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">GM_JQ.<span style="">type</span> = <span style="color:#CC0000;">'text/javascript'</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">document.<span style="">getElementsByTagName</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'head'</span><span style="color:#006600; font-weight:bold;">&#41;</span><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#93;</span>.<span style="">appendChild</span><span style="color:#006600; font-weight:bold;">&#40;</span>GM_JQ<span style="color:#006600; font-weight:bold;">&#41;</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>原文:<a href="http://www.learningjquery.com/2007/02/have-your-jquery-fun-on-any-site-with-greasemonkey">Have Your jQuery Fun on Any Site with Greasemonkey</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/346/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>过滤掉起点可恶的广告</title>
		<link>http://www.ooso.net/archives/323</link>
		<comments>http://www.ooso.net/archives/323#comments</comments>
		<pubDate>Tue, 19 Jun 2007 23:26:08 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[greasemonkey]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/323</guid>
		<description><![CDATA[有时候会跑到起点上去看书，打发无聊时光。但是起点的文章页不是太厚道，有一块狗皮膏药广告非常碍眼，牢牢的占据了屏幕右下方一块比较大的面积，这部分的字是看也看不到，很让人难受。
这时候祭出greasemonkey来教训它，写一点javascript就可以了：
document.getElementById("ifPage").style.display = "none";
上面的代码能把广告所在的div隐藏~~

				<span class="readmore"><a href="http://www.ooso.net/archives/323" title="过滤掉起点可恶的广告">阅读全文（234字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>有时候会跑到<a href="http://www.cmfu.com">起点</a>上去看书，打发无聊时光。但是起点的文章页不是太厚道，有一块狗皮膏药广告非常碍眼，牢牢的占据了屏幕右下方一块比较大的面积，这部分的字是看也看不到，很让人难受。</p>
<p>这时候祭出<a href="index.php?tag=greasemonkey">greasemonkey</a>来教训它，写一点javascript就可以了：<br />
<code>document.getElementById("ifPage").style.display = "none";</code></p>
<p>上面的代码能把广告所在的div隐藏~~</p>
<h1>greasemonkey脚本下载</h1>
<p><a href="http://www.ooso.net/wp-content/uploads/2007/CmfuReader.user.js">CmfuReader.user.js</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/323/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>在页面中动态载入外部javascript</title>
		<link>http://www.ooso.net/archives/312</link>
		<comments>http://www.ooso.net/archives/312#comments</comments>
		<pubDate>Tue, 12 Jun 2007 15:03:40 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[css]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/312</guid>
		<description><![CDATA[有时候需要在网页中某个div载入之后，动态引入一段javascript，IE下的解决方案：
PLAIN TEXT
CODE:


				<span class="readmore"><a href="http://www.ooso.net/archives/312" title="在页面中动态载入外部javascript">阅读全文（1144字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>有时候需要在网页中某个div载入之后，动态引入一段<a href="index.php?tag=javascript">javascript</a>，IE下的解决方案：</p>
<div class="igBar"><span id="lcode-59"><a href="#" onclick="javascript:showCodeTxt('code-59'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-59">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">newjs.<span style="">onreadystatechange</span> = function <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; if <span style="color:#006600; font-weight:bold;">&#40;</span>newjs.<span style="">readyState</span> == <span style="color:#CC0000;">'loaded'</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// ready!</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; newjs.<span style="">onload</span> = function <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// ready!</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>主要利用了onload以及onreadystatechange事件。把这个加以利用，也能动态载入外部css。下面是同时适合Ie/<a href="http://firefox.viewc.com">firefox</a>的写法。</p>
<p><span id="more-312"></span></p>
<div class="igBar"><span id="lcode-60"><a href="#" onclick="javascript:showCodeTxt('code-60'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-60">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var css;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">function include_css<span style="color:#006600; font-weight:bold;">&#40;</span>css_file<span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; var html_doc = document.<span style="">getElementsByTagName</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'head'</span><span style="color:#006600; font-weight:bold;">&#41;</span><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#93;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; css = document.<span style="">createElement</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'link'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; css.<span style="">setAttribute</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'rel'</span>, <span style="color:#CC0000;">'stylesheet'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; css.<span style="">setAttribute</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'type'</span>, <span style="color:#CC0000;">'text/css'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; css.<span style="">setAttribute</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'href'</span>, css_file<span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; html_doc.<span style="">appendChild</span><span style="color:#006600; font-weight:bold;">&#40;</span>css<span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#FF9933; font-style:italic;">// alert state change</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; css.<span style="">onreadystatechange</span> = function <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; if <span style="color:#006600; font-weight:bold;">&#40;</span>css.<span style="">readyState</span> == <span style="color:#CC0000;">'complete'</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; alert<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'CSS onreadystatechange fired'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; css.<span style="">onload</span> = function <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; alert<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'CSS onload fired'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; return false;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">var js;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">function include_js<span style="color:#006600; font-weight:bold;">&#40;</span>file<span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; var html_doc = document.<span style="">getElementsByTagName</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'head'</span><span style="color:#006600; font-weight:bold;">&#41;</span><span style="color:#006600; font-weight:bold;">&#91;</span><span style="color:#800000;color:#800000;">0</span><span style="color:#006600; font-weight:bold;">&#93;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; js = document.<span style="">createElement</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'script'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; js.<span style="">setAttribute</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'type'</span>, <span style="color:#CC0000;">'text/javascript'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; js.<span style="">setAttribute</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'src'</span>, file<span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; html_doc.<span style="">appendChild</span><span style="color:#006600; font-weight:bold;">&#40;</span>js<span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; js.<span style="">onreadystatechange</span> = function <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; if <span style="color:#006600; font-weight:bold;">&#40;</span>js.<span style="">readyState</span> == <span style="color:#CC0000;">'complete'</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; alert<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'JS onreadystate fired'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; js.<span style="">onload</span> = function <span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#006600; font-weight:bold;">&#123;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; &nbsp; &nbsp; alert<span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'JS onload fired'</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; <span style="color:#006600; font-weight:bold;">&#125;</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&nbsp; &nbsp; return false;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#125;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>这里是<a href="http://www.phpied.com/files/jinc/test_ready_onload.html">Demo</a>，有动态载入css以及js的例子。</p>
<h1>原文地址</h1>
<p><a href="http://www.phpied.com/javascript-include-ready-onload/">http://www.phpied.com/javascript-include-ready-onload/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/312/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>YUI 2.3.0 即将发布</title>
		<link>http://www.ooso.net/archives/318</link>
		<comments>http://www.ooso.net/archives/318#comments</comments>
		<pubDate>Mon, 11 Jun 2007 00:07:14 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[yui]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/318</guid>
		<description><![CDATA[YUI 2.3.0 即将发布,最迟七月份可以看到。新的YUI组件和特点:

1.  Rich Text Editor
The YUI RTE beta comprises an editor window and toolbar, the latter of which has a simple, extensible plugin architecture.  It will feature full A-grade support.  (Dav Glass)

				<span class="readmore"><a href="http://www.ooso.net/archives/318" title="YUI 2.3.0 即将发布">阅读全文（2057字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>YUI 2.3.0 即将发布,最迟七月份可以看到。新的<a href="http://developer.yahoo.com/yui/">YUI</a>组件和特点:</p>
<blockquote><p>
1.  Rich Text Editor<br />
The <a href="index.php?tag=yui">YUI</a> RTE beta comprises an editor window and toolbar, the latter of which has a simple, extensible plugin architecture.  It will feature full A-grade support.  (Dav Glass)</p>
<p>2.  ImageLoader Utility<br />
Images often constitute the most data-heavy parts of a page, but many times users load images that they never see — because the image is below the fold, because it is in an obscured tab in a TabView, etc.  The YUI ImageLoader is a new, experimental component that allows you to defer the loading of images based on criteria you specify and to then load those images when a specific "trigger" is hit.  In some cases, use of ImageLoader can significantly reduce bandwidth and increase performance. (Matt Mlinac)</p>
<p>3.  Base CSS<br />
YUI's Reset CSS normalizes browser CSS styles by stripping out browser-defined styles; this allows you to begin your CSS styles with all style decisions being intentional rather than inherited.  YUI's Base CSS will help you begin the process of making your styles intentional by providing a common set of treatments that most implementations share. (Nate Koechley)</p>
<p>4.  Color Picker<br />
Previous versions of YUI shipped a Color Picker example as part of the Slider Control.  In 2.3, we're formalizing Color Picker and completing its API to make it easier to implement this powerful control in your apps. (Adam Moore)</p></blockquote>
<p>Notable Changes to Existing Components:</p>
<blockquote><p>1.  Button<br />
Button remains in beta as we modify the architecture a bit.  As of 2.3, the SplitButton implementation will replace MenuButton and be generic — allowing you to implement Buttons that have Menus or any other sub-control you wish. (Todd Kloots)</p>
<p>2.  Connection Manager<br />
YUI's XHR utility will be enhanced with a Custom Event API that adds granularity to the interesting moments you can pipe into on your XHR transactions. (Thomas Sha)</p>
<p>3.  DataTable<br />
DataTable will undergo a major rearchitecture as it evolves to its second beta.  Details on the DataTable evolution for 2.3 will be presented during an open conference call for all interested implementers during the second half of June.  An invitation to the call will be sent out to this list a week prior to that call. (Jenny Han)</p>
<p>4.  Browser History Manager<br />
Browser History Manager comes out of experimental status with 2.3 and is promoted to beta, accompanied by several bug fixes and some key enhancements requested by YUI implementers during the experimental phase. (Julien Lecomte)</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/318/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>inline-js 0.3 &#8212; wordpress插件</title>
		<link>http://www.ooso.net/archives/290</link>
		<comments>http://www.ooso.net/archives/290#comments</comments>
		<pubDate>Thu, 10 May 2007 15:26:31 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[javascript]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/290</guid>
		<description><![CDATA[最近加班比较多，时间相当的紧张，今天终于得闲把inline-js升级了。这个版本对最初的插件处理方式做了改进，不再粗暴的中止其它the_content filter的运行:)
Plugin Name: Inline Javascript Plugin
Plugin URI: http://www.ooso.net/index.php/inline-js/
Feed URI: http://www.ooso.net/index.php/feed/

				<span class="readmore"><a href="http://www.ooso.net/archives/290" title="inline-js 0.3 &#8212; wordpress插件">阅读全文（789字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>最近加班比较多，时间相当的紧张，今天终于得闲把<a href="http://www.ooso.net/index.php/inline-js">inline-js</a>升级了。这个版本对最初的插件处理方式做了改进，不再粗暴的中止其它the_content filter的运行:)</p>
<blockquote><p>Plugin Name: Inline Javascript Plugin<br />
Plugin URI: http://www.ooso.net/index.php/inline-js/<br />
Feed URI: http://www.ooso.net/index.php/feed/<br />
Description: Plugin that insert inline javascript in Posts/Pages<br />
Version: 0.3<br />
Author: Volcano<br />
Author URI: http://www.ooso.net</p></blockquote>
<h3>使用方法</h3>
<ul>
<li>解压</li>
<li>Copy inline-js.php到目录wp-contents/plugin并激活插件.</li>
<li>用标签<strong>[inline]</strong> and <strong>[/inline]</strong>围绕你要发表的javascript,and post it</li>
<li>Ok</li>
</ul>
<p><span id="more-290"></span></p>
<h3>Usage</h3>
<ul>
<li>Unzip</li>
<li>Copy inline-js.php to direcotry wp-contents/plugin and activate the plugin.</li>
<li>Use <strong>[inline]</strong> and <strong>[/inline]</strong> tag around the javascript,and post it</li>
<li>Ok</li>
</ul>
<h3>Example</h3>
<div class="igBar"><span id="lcode-62"><a href="#" onclick="javascript:showCodeTxt('code-62'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-62">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span>inline<span style="color:#006600; font-weight:bold;">&#93;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;script type=<span style="color:#CC0000;">"text/javascript"</span>&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">document.<span style="">write</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">"hello world!"</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">&lt;/script&gt;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">&#91;</span>/inline<span style="color:#006600; font-weight:bold;">&#93;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<h3>Download</h3>
<p><a id=p233 href="http://www.ooso.net/wp-content/uploads/2006/08/inline-js-0.3.zip">latest inline-js plugin</a></p>
<h3>inline-js的主题页</h3>
<p>这个页面会记录inline-js的更新情况。<br />
<a href="http://www.ooso.net/index.php/inline-js">http://www.ooso.net/index.php/inline-js</a></p>
<p>俺在wp-plugins.net上的相关链接：<br />
<a href="http://wp-plugins.net/author/volcano/">http://wp-plugins.net/author/volcano/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/290/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>
