<?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>FV.Zone &#187; 技术开发</title>
	<atom:link href="http://fvzone.com/blog/tag/%e6%8a%80%e6%9c%af%e5%bc%80%e5%8f%91/feed" rel="self" type="application/rss+xml" />
	<link>http://fvzone.com/blog</link>
	<description>生命最快乐时,就是与你分享时!</description>
	<lastBuildDate>Fri, 28 May 2010 16:30:20 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Ajax基础教程</title>
		<link>http://fvzone.com/blog/ajax%e5%9f%ba%e7%a1%80%e6%95%99%e7%a8%8b.fv</link>
		<comments>http://fvzone.com/blog/ajax%e5%9f%ba%e7%a1%80%e6%95%99%e7%a8%8b.fv#comments</comments>
		<pubDate>Wed, 01 Feb 2006 07:46:09 +0000</pubDate>
		<dc:creator>Fvart</dc:creator>
				<category><![CDATA[JQuery Ajax]]></category>
		<category><![CDATA[Ajax]]></category>
		<category><![CDATA[技术开发]]></category>

		<guid isPermaLink="false">http://www.rcsky.org/blog/?p=6</guid>
		<description><![CDATA[      AJAX (异步 JavaScript 和 XML) 是个新产生的术语,专为描述JavaScript的两项强大性能.这两项性能在多年来一直被网络开发者所忽略,直到最近Gmail, Google suggest和google Maps的横空出世才使人们开始意... ]]></description>
			<content:encoded><![CDATA[<p>      AJAX (异步 JavaScript 和 XML) 是个新产生的术语,专为描述JavaScript的两项强大性能.这两项性能在多年来一直被网络开发者所忽略,直到最近Gmail, Google suggest和google Maps的横空出世才使人们开始意识到其重要性.<span id="more-6"></span></p>
<p>这两项被忽视的性能是:</p>
<p>• 无需重新装载整个页面便能向服务器发送请求.</p>
<p>• 对XML文档的解析和处理．</p>
<p>步骤 1 – &#8220;请!&#8221; &#8212; 如何发送一个HTTP请求</p>
<p>为了用JavaScript向服务器发送一个HTTP请求, 需要一个具备这种功能的类实例. 这样的类首先由Internet Explorer以ActiveX对象引入, 被称为XMLHTTP. 后来Mozilla, Safari 和其他浏览器纷纷仿效, 提供了XMLHttpRequest类,它支持微软的ActiveX对象所提供的方法和属性.</p>
<p>因此, 为了创建一个跨浏览器的这样的类实例(对象), 可以应用如下代码:</p>
<pre class="syntax-highlight:php">if (window.XMLHttpRequest) { // Mozilla, Safari, ...

http_request = new XMLHttpRequest();

} else if (window.ActiveXObject) { // IE

http_request = new ActiveXObject(&quot;Microsoft.XMLHTTP&quot;);

}
</pre>
<p>(上例对代码做了一定简化,这是为了解释如何创建XMLHTTP类实例. 实际的代码实例可参阅本篇步骤3.)</p>
<p>如果服务器的响应没有XML mime-type header,某些Mozilla浏览器可能无法正常工作. 为了解决这个问题, 如果服务器响应的header不是text/xml,可以调用其它方法修改该header.</p>
<pre class="syntax-highlight:php">http_request = new XMLHttpRequest();

http_request.overrideMimeType(&#039;text/xml&#039;);</pre>
<p>接下来要决定当收到服务器的响应后,需要做什么.这需要告诉HTTP请求对象用哪一个JavaScript函数处理这个响应.可以将对象的onreadystatechange属性设置为要使用的JavaScript的函数名,如下所示:</p>
<pre class="syntax-highlight:php">http_request.onreadystatechange = nameOfTheFunction;

注意:在函数名后没有括号,也无需传递参数.另外还有一种方法,可以在扉页(fly)中定义函数及其对响应要采取的行为,如下所示:

[php]http_request.onreadystatechange = function(){

// do the thing

};</pre>
<p>在定义了如何处理响应后,就要发送请求了.可以调用HTTP请求类的open()和send()方法, 如下所示:</p>
<pre class="syntax-highlight:php">http_request.open(&#039;GET&#039;, &#039;http://www.example.org/some.file&#039;, true);

http_request.send(null);</pre>
<p>• open()的第一个参数是HTTP请求方式 – GET, POST, HEAD 或任何服务器所支持的您想调用的方式. 按照HTTP规范,该参数要大写;否则,某些浏览器(如Firefox)可能无法处理请求.有关HTTP请求方法的详细信息可参考http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html W3C specs</p>
<p>• 第二个参数是请求页面的URL.由于自身安全特性的限制,该页面不能为第三方域名的页面.同时一定要保证在所有的页面中都使用准确的域名,否则调用open()会得到&#8221;permission denied&#8221;的错误提示.一个常见的错误是访问站点时使用domain.tld,而当请求页面时,却使用www.domain.tld.</p>
<p>• 第三个参数设置请求是否为异步模式.如果是TRUE, JavaScript函数将继续执行,而不等待服务器响应.这就是&#8221;AJAX&#8221;中的&#8221;A&#8221;.</p>
<p>如果第一个参数是&#8221;POST&#8221;,send()方法的参数可以是任何想送给服务器的数据. 这时数据要以字符串的形式送给服务器,如下所示:<br />
name=value&amp;anothername=othervalue&amp;so=on<br />
步骤 2 – &#8220;收到!&#8221; &#8212; 处理服务器的响应</p>
<p>当发送请求时,要提供指定处理响应的JavaScript函数名.</p>
<pre class="syntax-highlight:php">http_request.onreadystatechange = nameOfTheFunction;</pre>
<p>我们来看看这个函数的功能是什么.首先函数会检查请求的状态.如果状态值是4,就意味着一个完整的服务器响应已经收到了,您将可以处理该响应.</p>
<pre class="syntax-highlight:php">if (http_request.readyState == 4) {

// everything is good, the response is received

} else {

// still not ready

}</pre>
<p>readyState的取值如下:</p>
<p>• 0 (未初始化)</p>
<p>• 1 (正在装载)</p>
<p>• 2 (装载完毕)</p>
<p>• 3 (交互中)</p>
<p>• 4 (完成)</p>
<p>(Source)</p>
<p>接着,函数会检查HTTP服务器响应的状态值. 完整的状态取值可参见 W3C site. 我们着重看值为200 OK的响应.</p>
<pre class="syntax-highlight:php">if (http_request.status == 200) {

// perfect!

} else {

// there was a problem with the request,

// for example the response may be a 404 (Not Found)

// or 500 (Internal Server Error) response codes

}</pre>
<p>在检查完请求的状态值和响应的HTTP状态值后, 您就可以处理从服务器得到的数据了.有两种方式可以得到这些数据:</p>
<p>• http_request.responseText – 以文本字符串的方式返回服务器的响应</p>
<p>• http_request.responseXML – 以XMLDocument对象方式返回响应.处理XMLDocument对象可以用JavaScript DOM函数</p>
<p>步骤 3 – &#8220;万事俱备!&#8221; &#8211; 简单实例</p>
<p>我们现在将整个过程完整地做一次,发送一个简单的HTTP请求. 我们用JavaScript请求一个HTML文件, test.html, 文件的文本内容为&#8221;I&#8217;m a test.&#8221;.然后我们&#8221;alert()&#8221;test.html文件的内容.</p>
<pre class="syntax-highlight:php">style=&quot;cursor: pointer; text-decoration: underline&quot;
onclick=&quot;makeRequest(&#039;test.html&#039;)&quot;&amp;gt;

Make a request
</pre>
<p>本例中:</p>
<p>• 用户点击浏览器上的&#8221;请求&#8221;链接;</p>
<p>• 接着函数makeRequest()将被调用.其参数 – HTML文件test.html在同一目录下;</p>
<p>• 这样就发起了一个请求.onreadystatechange的执行结果会被传送给alertContents();</p>
<p>• alertContents()将检查服务器的响应是否成功地收到,如果是,就会&#8221;alert()&#8221;test.html文件的内容.<br />
步骤 4 – &#8220;X-文档&#8221; &#8212; 处理XML响应</p>
<p>在前面的例子中,当服务器对HTTP请求的响应被收到后,我们会调用请求对象的reponseText属性.该属性包含了test.html文件的内容.现在我们来试试responseXML属性.</p>
<p>首先,我们新建一个有效的XML文件,后面我们将使用这个文件.该文件(test.xml)源代码如下所示:</p>
<p>I&#8217;m a test.</p>
<p>在该脚本中,我们只需修改请求部分:</p>
<pre class="syntax-highlight:php">...

onclick=&quot;makeRequest(&#039;test.xml&#039;)&quot;&amp;gt;

...
</pre>
<p>接着,在alertContents()中,我们将alert()的代码alert(http_request.responseText);换成:</p>
<pre class="syntax-highlight:php">var xmldoc = http_request.responseXML;

var root_node = xmldoc.getElementsByTagName(&#039;root&#039;).item(0);

alert(root_node.firstChild.data);</pre>
<p>这里,我们使用了responseXML提供的XMLDocument对象并用DOM方法获取存于XML文件中的内容.</p>
]]></content:encoded>
			<wfw:commentRss>http://fvzone.com/blog/ajax%e5%9f%ba%e7%a1%80%e6%95%99%e7%a8%8b.fv/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>TabPane Plugin 发布</title>
		<link>http://fvzone.com/blog/tabpane-plugin-%e5%8f%91%e5%b8%83.fv</link>
		<comments>http://fvzone.com/blog/tabpane-plugin-%e5%8f%91%e5%b8%83.fv#comments</comments>
		<pubDate>Wed, 01 Feb 2006 07:38:58 +0000</pubDate>
		<dc:creator>Fvart</dc:creator>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Plugin]]></category>
		<category><![CDATA[技术开发]]></category>

		<guid isPermaLink="false">http://www.rcsky.org/blog/?p=5</guid>
		<description><![CDATA[   本次发布的tabpane plugin 只是为了让大家更好的使用 tabpane，本程序不是我写的，我只是把它插件化了。
我们一直在想怎么让你一看就能明白，就能轻松的用上它，那怕只是一点点的改进我们... ]]></description>
			<content:encoded><![CDATA[<p>   本次发布的tabpane plugin 只是为了让大家更好的使用 tabpane，本程序不是我写的，我只是把它插件化了。<br />
我们一直在想怎么让你一看就能明白，就能轻松的用上它，那怕只是一点点的改进我们都愿意做，关于这个tabpane插件的用法也很简单<span id="more-5"></span></p>
<p>原作者网站:http://webfx.eae.net/<br />
OSYE 插件化:http://blog.rcsky.org,wwww.osye.com<br />
<a href="http://www.rcsky.org/soft/tabpane.rar">本地下载</a><br />
<a href="http://blog.rcsky.org">本站演示</a><br />
你只要将它传到wp-content/plugins/里去，和文件夹，在后台激活，就这样tabpane的JS文件和CSS文件就被加载到了模板的核心，你只要在模板文件的任何地方调用下面的代码就可以使tabpane工作。<br />
当时的tabpane是要放到空间的一个地方去，要使用绝对路径才能工作，要修改很多地方才能做到，对于换模板很不好，这样我们把它插件化了，将它放到插件目录，这样就把tabpane完全的插件化了。<br />
也模决化了，不知道你感觉到没？如果你在使用本插件时什么问题好的建议请联系我，祝大家新年快乐~！<br />
因为时间原因，我没有详细说明用法，下面的代码是我BLOG的工具栏的调用的代码，你可以作一些参考：</p>
<pre class="syntax-highlight:php">
&lt;p style=&quot;float: right&quot;&gt;&amp;nbsp;&lt;/p&gt;
&lt;p class=&quot;tab-pane&quot; id=&quot;tab-pane-1&quot;&gt; &lt;script type=&quot;text/javascript&quot;&gt;var tabPane1 = new WebFXTabPane( document.getElementById( &quot;tab-pane-1&quot; ) );&lt;/script&gt;&lt;/p&gt;
&lt;p class=&quot;tab-page&quot; id=&quot;tab-page-1&quot;&gt;&amp;nbsp;&lt;/p&gt;

&lt;h2 class=&quot;tab&quot;&gt;General&lt;abbr title=&quot;XHTML Friends Network&quot;&gt;&lt;/abbr&gt;&lt;/h2&gt;
&lt;script type=&quot;text/javascript&quot;&gt;tabPane1.addTabPage( document.getElementById( &quot;tab-page-1&quot; ) );&lt;/script&gt;

&lt;center&gt; &lt;/center&gt;
&lt;p class=&quot;tab-page&quot; id=&quot;tab-page-2&quot;&gt;&amp;nbsp;&lt;/p&gt;

&lt;h2 class=&quot;tab&quot;&gt;Music&lt;/h2&gt;
&lt;script type=&quot;text/javascript&quot;&gt;tabPane1.addTabPage( document.getElementById( &quot;tab-page-2&quot; ) );&lt;/script&gt;                            &lt;iframe src=&quot;http://blog.raidybor.com/wp-admin/%3C?php%20bloginfo%28%27stylesheet_directory%27%29;%20?%3E/player/player.php&quot; border=&quot;0&quot; frameborder=&quot;0&quot; height=&quot;220&quot; scrolling=&quot;no&quot; width=&quot;200&quot;&gt;&lt;/iframe&gt;
&lt;p class=&quot;tab-page&quot; id=&quot;tab-page-3&quot;&gt;&amp;nbsp;&lt;/p&gt;

&lt;h2 class=&quot;tab&quot;&gt;Message&lt;/h2&gt;
&lt;script type=&quot;text/javascript&quot;&gt;tabPane1.addTabPage( document.getElementById( &quot;tab-page-3&quot; ) );&lt;/script&gt;
&lt;p class=&quot;tab-page&quot; id=&quot;tab-page-4&quot;&gt;&amp;nbsp;&lt;/p&gt;

&lt;h2 class=&quot;tab&quot;&gt;Votes&lt;/h2&gt;
&lt;script type=&quot;text/javascript&quot;&gt;tabPane1.addTabPage( document.getElementById( &quot;tab-page-4&quot; ) );&lt;/script&gt;
</pre>
<p>原作者网站:http://webfx.eae.net/<br />
OSYE 插件化:http://blog.rcsky.org,wwww.osye.com</p>
]]></content:encoded>
			<wfw:commentRss>http://fvzone.com/blog/tabpane-plugin-%e5%8f%91%e5%b8%83.fv/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Rcsky titles 发布</title>
		<link>http://fvzone.com/blog/rcsky-titles-%e5%8f%91%e5%b8%83.fv</link>
		<comments>http://fvzone.com/blog/rcsky-titles-%e5%8f%91%e5%b8%83.fv#comments</comments>
		<pubDate>Wed, 01 Feb 2006 06:17:00 +0000</pubDate>
		<dc:creator>Fvart</dc:creator>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[Plugin]]></category>
		<category><![CDATA[技术开发]]></category>

		<guid isPermaLink="false">http://www.rcsky.org/blog/?p=3</guid>
		<description><![CDATA[RcSky titles是一种当鼠标停在标题或是链接上的时候给出一个提示的小插件,用于美比你的BLOG,一直喜欢这个东西,今天终于找到了他,为了大家使用方便我做成了插件,欢迎大家使用.
原作者不是我.... ]]></description>
			<content:encoded><![CDATA[<p>RcSky titles是一种当鼠标停在标题或是链接上的时候给出一个提示的小插件,用于美比你的BLOG,一直喜欢这个东西,今天终于找到了他,为了大家使用方便我做成了插件,欢迎大家使用.<br />
<strong>原作者不是我.我只是因为改动较大,所以改名</strong><span id="more-3"></span><br />
原作者网站:http://www.remus.dti.ne.jp/~a-satomi/<br />
bunsyorou/ArekorePopup.html<br />
<strong>注意:如果你用的是K2模板因为冲突在Mozilla Firefox下没有效果,暂时还不知道因原因,我们会尽快修正</strong></p>
<p>演示：<a href="http://www.rcsky.org" title="演示效果">请点击</a><br />
<a href="http://www.rcsky.org/soft/RcSky%20titles.rar">1、下载RcSky titles</a><br />
安装方法:2、将RcSky titles.rar解压缩传至：</p>
<pre class="syntax-highlight:php">/wp-content/plugins/************
/wp-content/plugins/RcSky titles/
/RcSky titles.php
/README.txt
/RcSky titles/ArekorePopup.css
/RcSky titles/ArekorePopup.js
/RcSky titles/Firefox.js
/RcSky titles/body.png
/RcSky titles/bottom.png
/RcSky titles/bottom-left.png
/RcSky titles/bottom-right.png
/RcSky titles/left.png
/RcSky titles/right.png
/RcSky titles/top.png
/RcSky titles/top-left.png
/RcSky titles/top-right.png</pre>
<p>3、进入管理后台，在插件下找到RcSky titles 激活便可以使用，不需要任何修改~！祝大家新年快乐~!</p>
]]></content:encoded>
			<wfw:commentRss>http://fvzone.com/blog/rcsky-titles-%e5%8f%91%e5%b8%83.fv/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>
