<?xml version="1.0" encoding="UTF-8"  standalone="yes" ?>
<rss version="2.0">
	<channel>
		<title>社群: Web Programming - 文件區(plugin)</title>
		<description>台灣數位學習數位教學平台 RSS feed provider</description>
		<language>zh-tw</language>
		<link>http://lms.xms.com.tw/board.php?courseID=100&amp;f=doclist&amp;folderID=1605</link>
	<item>
		<title>好用的擴充</title>
		<link>http://lms.xms.com.tw/board.php?courseID=100&amp;f=doc&amp;cid=8667</link>
		<description>在 form 中設定 readonly 並變顏色，測試範例 [form.setReadOnly.html、chapter7.setReadOnly.rar](function($) {&amp;nbsp; &amp;nbsp; $.fn.setReadOnly = function(readonly) {&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return this.filter(&#039;input:text&#039;)&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; .attr(&#039;readOnly&#039;, readonly)&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; .css(&#039;opacity&#039;, readonly ? 0.5 : 1.0)&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; .end();&amp;nbsp; &amp;nbsp; };})(jQuery); </description>
		<pubDate>Sat, 16 Jun 2012 09:17:19 +0800</pubDate>
	</item>
	<item>
		<title>擴充的模式 - 確保 $ 可用 (包進立即執行函數中)</title>
		<link>http://lms.xms.com.tw/board.php?courseID=100&amp;f=doc&amp;cid=8666</link>
		<description>jQuery 習慣用 $ 來使用，但 $ 卻可能被其他定義所覆蓋，例如共用 prototype.js 時解法: 將 jQeury 用 $ 封裝到立即函數中(function($) {&amp;nbsp; $.say = function(msg) {&amp;nbsp; &amp;nbsp; &amp;nbsp;...&amp;nbsp; }})(jQuery);$.fn 擴充 jQuery wrapper(function($) {&amp;nbsp; $.fn.makeItBlue = function() {&amp;nbsp; &amp;nbsp; return this.css(&#039;color&#039;: &#039;blue&#039;); &amp;nbsp;// jQuery chain&amp;nbsp; }})(jQuery);$.fn 中的 each() 的技巧(function($) {&amp;nbsp; $.fn.makeItBlue = function() {&amp;nbsp; &amp;nbsp; return this.each( &amp;nbsp;// jQuery chain&amp;nbsp; &amp;nbsp; &amp;nbsp; function() {&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; $(this).css(&#039;color&#039;: &#039;blue&#039;);&amp;nbsp; &amp;nbsp; &amp;nbsp; }&amp;nbsp; &amp;nbsp; );&amp;nbsp; &amp;nbsp; 或是直接用函數的方法進行迭代&amp;nbsp; &amp;nbsp;&amp;nbsp;return this.css(&#039;color&#039;:&amp;nbsp; &amp;nbsp; &amp;nbsp; function() {&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return $(this).css(&#039;color&#039;: &#039;blue&#039;);&amp;nbsp; &amp;nbsp; &amp;nbsp; }&amp;nbsp; &amp;nbsp; );&amp;nbsp; }})(jQuery);         </description>
		<pubDate>Sat, 16 Jun 2012 08:52:56 +0800</pubDate>
	</item>
	<item>
		<title>參數傳遞 - $.extend() 技巧</title>
		<link>http://lms.xms.com.tw/board.php?courseID=100&amp;f=doc&amp;cid=8665</link>
		<description>傳遞多個參數時，最好使用 json 的方式 (options hash)，尤其是可省略的參數例如:var options = {&amp;nbsp; opt1: value1,&amp;nbsp; opt2: value2,&amp;nbsp; ...}並使用 $.extend() 合併參數與預設值function foo(options) {&amp;nbsp; var settings = $.extend({&amp;nbsp; &amp;nbsp; opt1: null, &amp;nbsp;// 列出所有的選項，對程式可讀性是非常有益且明智的&amp;nbsp; &amp;nbsp; opt2: default2,&amp;nbsp; &amp;nbsp; ...&amp;nbsp; &amp;nbsp; opt9: default9&amp;nbsp; }, options || {};&amp;nbsp; // function definition ..}       </description>
		<pubDate>Sat, 16 Jun 2012 08:44:38 +0800</pubDate>
	</item>
	</channel>
	</rss>
