<?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>phill84.org &#187; script</title>
	<atom:link href="http://phill84.org/tag/script/feed/" rel="self" type="application/rss+xml" />
	<link>http://phill84.org</link>
	<description>System.out.print</description>
	<lastBuildDate>Sat, 26 Mar 2011 10:21:26 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>豆瓣小組引用回復插件</title>
		<link>http://phill84.org/2009/06/%e8%b1%86%e7%93%a3%e5%b0%8f%e7%b5%84%e5%bc%95%e7%94%a8%e5%9b%9e%e5%be%a9%e6%8f%92%e4%bb%b6/</link>
		<comments>http://phill84.org/2009/06/%e8%b1%86%e7%93%a3%e5%b0%8f%e7%b5%84%e5%bc%95%e7%94%a8%e5%9b%9e%e5%be%a9%e6%8f%92%e4%bb%b6/#comments</comments>
		<pubDate>Wed, 03 Jun 2009 13:59:13 +0000</pubDate>
		<dc:creator>phill84</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[douban]]></category>
		<category><![CDATA[greasemonkey]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[插件]]></category>
		<category><![CDATA[豆瓣]]></category>

		<guid isPermaLink="false">http://phill84.org/2009/06/%e8%b1%86%e7%93%a3%e5%b0%8f%e7%b5%84%e5%bc%95%e7%94%a8%e5%9b%9e%e5%be%a9%e6%8f%92%e4%bb%b6/</guid>
		<description><![CDATA[在顯示樓層插件的基礎上加上了引用回復功能 因為是以顯示樓層插件為基礎, 所以要求依然是 firefox+greasemonkey, 並且包括顯示樓層功能 引用回復的 link 只有在鼠標在回復區塊上時才會顯示 如果想引用留言所在頁面不是最後一頁, 因此沒有回復框, 插件會自動在頁面上加上回復框 引用完成後頁面會滾動到底部回復框 * 增加: ctrl+enter 回復功能 (04/06/2009) * 修正bug: 不能在非第一頁或最後頁創建回復框 (10/06/2009) * 增加: 如果討論分頁, 在頁首也顯示導航條 (10/06/2009) 顯示效果如下圖 請點這裡安裝]]></description>
			<content:encoded><![CDATA[<p>在顯示樓層插件的基礎上加上了引用回復功能</p>
<p>因為是以顯示樓層插件為基礎, 所以要求依然是 firefox+greasemonkey, 並且包括顯示樓層功能</p>
<p>引用回復的 link 只有在鼠標在回復區塊上時才會顯示</p>
<p>如果想引用留言所在頁面不是最後一頁, 因此沒有回復框, 插件會自動在頁面上加上回復框</p>
<p>引用完成後頁面會滾動到底部回復框</p>
<p><span style="color: #993300;">* 增加: ctrl+enter 回復功能 (04/06/2009)</span><br />
<span style="color: #993300;">* 修正bug: 不能在非第一頁或最後頁創建回復框 (10/06/2009)</span><br />
<span style="color: #993300;">* 增加: 如果討論分頁, 在頁首也顯示導航條</span><span style="color: #993300;"> (10/06/2009)</span></p>
<p><span id="more-592"></span>顯示效果如下圖</p>
<blockquote><p><a href="http://phill84.org/wp-content/uploads/2009/06/screenshot.png"><img class="alignnone size-full wp-image-591 colorbox-592" title="Screenshot" src="http://phill84.org/wp-content/uploads/2009/06/screenshot.png" alt="screenshot 豆瓣小組引用回復插件" width="641" height="446" /></a></p></blockquote>
<p>請點<a href="http://userscripts.org/scripts/show/50759">這裡</a>安裝</p>
]]></content:encoded>
			<wfw:commentRss>http://phill84.org/2009/06/%e8%b1%86%e7%93%a3%e5%b0%8f%e7%b5%84%e5%bc%95%e7%94%a8%e5%9b%9e%e5%be%a9%e6%8f%92%e4%bb%b6/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>豆瓣討論區顯示樓層數GreaseMonkey插件</title>
		<link>http://phill84.org/2009/06/%e8%b1%86%e7%93%a3%e8%a8%8e%e8%ab%96%e5%8d%80%e9%a1%af%e7%a4%ba%e6%a8%93%e5%b1%a4%e6%95%b8greasemonkey%e6%8f%92%e4%bb%b6/</link>
		<comments>http://phill84.org/2009/06/%e8%b1%86%e7%93%a3%e8%a8%8e%e8%ab%96%e5%8d%80%e9%a1%af%e7%a4%ba%e6%a8%93%e5%b1%a4%e6%95%b8greasemonkey%e6%8f%92%e4%bb%b6/#comments</comments>
		<pubDate>Tue, 02 Jun 2009 17:42:51 +0000</pubDate>
		<dc:creator>phill84</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[douban]]></category>
		<category><![CDATA[greasemonkey]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[豆瓣]]></category>

		<guid isPermaLink="false">http://phill84.org/2009/06/%e8%b1%86%e7%93%a3%e8%a8%8e%e8%ab%96%e5%8d%80%e9%a1%af%e7%a4%ba%e6%a8%93%e5%b1%a4%e6%95%b8greasemonkey%e6%8f%92%e4%bb%b6/</guid>
		<description><![CDATA[如題 requirements 是 firefox + greasemonkey 啟用後的效果如下 * NOTE: 此插件已不再更新，且因為豆瓣更改頁面布局此插件業已失效，請點擊 這裡 查看豆瓣引用回覆插件]]></description>
			<content:encoded><![CDATA[<p>如題</p>
<p>requirements 是 firefox + greasemonkey</p>
<p>啟用後的效果如下</p>
<blockquote><p><a href="http://phill84.org/wp-content/uploads/2009/06/screenshot_1.png"><img class="alignnone size-full wp-image-588 colorbox-590" title="Screenshot" src="http://phill84.org/wp-content/uploads/2009/06/screenshot_1.png" alt="screenshot 1 豆瓣討論區顯示樓層數GreaseMonkey插件" width="298" height="449" /></a></p></blockquote>
<p><span id="more-590"></span></p>
<blockquote><p><a href="http://phill84.org/wp-content/uploads/2009/06/screenshot_2.png"><img class="alignnone size-medium wp-image-589 colorbox-590" title="Screenshot" src="http://phill84.org/wp-content/uploads/2009/06/screenshot_2-449x147.png" alt="screenshot 2 449x147 豆瓣討論區顯示樓層數GreaseMonkey插件" width="449" height="147" /></a></p></blockquote>
<p><span style="color: #ff0000;">* NOTE: 此插件已不再更新，且因為豆瓣更改頁面布局此插件業已失效，請點擊 <a href="http://phill84.org/2009/06/%E8%B1%86%E7%93%A3%E5%B0%8F%E7%B5%84%E5%BC%95%E7%94%A8%E5%9B%9E%E5%BE%A9%E6%8F%92%E4%BB%B6/">這裡</a> 查看豆瓣引用回覆插件</span></p>
]]></content:encoded>
			<wfw:commentRss>http://phill84.org/2009/06/%e8%b1%86%e7%93%a3%e8%a8%8e%e8%ab%96%e5%8d%80%e9%a1%af%e7%a4%ba%e6%a8%93%e5%b1%a4%e6%95%b8greasemonkey%e6%8f%92%e4%bb%b6/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>a bash script to control spawn-fcgi as a service</title>
		<link>http://phill84.org/2008/11/a-bash-script-to-control-spawn-fcgi-as-a-service/</link>
		<comments>http://phill84.org/2008/11/a-bash-script-to-control-spawn-fcgi-as-a-service/#comments</comments>
		<pubDate>Sat, 29 Nov 2008 22:24:46 +0000</pubDate>
		<dc:creator>phill84</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[init.d]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[service]]></category>
		<category><![CDATA[spawn-fcgi]]></category>

		<guid isPermaLink="false">http://phill84.org/?p=427</guid>
		<description><![CDATA[first create a file named &#8220;php-fastcgi&#8221; in /usr/bin/, suppose your spawn-fcgi is in /usr/bin/, don&#8217;t forget to chmod +x on the file 1 2 #!/bin/sh /usr/bin/spawn-fcgi -a 127.0.0.1 -p 9000 -u www-data -f /usr/bin/php5-cgi then create another file named &#8220;init-fastcgi&#8221; &#8230; <a href="http://phill84.org/2008/11/a-bash-script-to-control-spawn-fcgi-as-a-service/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>first create a file named &#8220;php-fastcgi&#8221; in /usr/bin/, suppose your spawn-fcgi is in /usr/bin/, don&#8217;t forget to chmod +x on the file</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
</pre></td><td class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">#!/bin/sh</span>
<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>spawn-fcgi <span style="color: #660033;">-a</span> 127.0.0.1 <span style="color: #660033;">-p</span> <span style="color: #000000;">9000</span> <span style="color: #660033;">-u</span> www-data <span style="color: #660033;">-f</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>php5-cgi</pre></td></tr></table></div>

<p>then create another file named &#8220;init-fastcgi&#8221; in /etc/init.d/ and run &#8220;sudo update-rc.d init-fastcgi defaults&#8221;</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
</pre></td><td class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">#!/bin/bash</span>
<span style="color: #007800;">PHP_SCRIPT</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>php-fastcgi
<span style="color: #007800;">RETVAL</span>=<span style="color: #000000;">0</span>
<span style="color: #000000; font-weight: bold;">case</span> <span style="color: #ff0000;">&quot;$1&quot;</span> <span style="color: #000000; font-weight: bold;">in</span>
    start<span style="color: #7a0874; font-weight: bold;">&#41;</span>
      <span style="color: #007800;">$PHP_SCRIPT</span>
      <span style="color: #007800;">RETVAL</span>=<span style="color: #007800;">$?</span>
  <span style="color: #000000; font-weight: bold;">;;</span>
    stop<span style="color: #7a0874; font-weight: bold;">&#41;</span>
      <span style="color: #c20cb9; font-weight: bold;">killall</span> <span style="color: #660033;">-9</span> php5-cgi
      <span style="color: #007800;">RETVAL</span>=<span style="color: #007800;">$?</span>
  <span style="color: #000000; font-weight: bold;">;;</span>
    restart<span style="color: #7a0874; font-weight: bold;">&#41;</span>
      <span style="color: #c20cb9; font-weight: bold;">killall</span> <span style="color: #660033;">-9</span> php5-cgi
      <span style="color: #c20cb9; font-weight: bold;">sleep</span> <span style="color: #000000;">0.5</span>
      <span style="color: #007800;">$PHP_SCRIPT</span>
      <span style="color: #007800;">RETVAL</span>=<span style="color: #007800;">$?</span>
  <span style="color: #000000; font-weight: bold;">;;</span>
    <span style="color: #000000; font-weight: bold;">*</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
      <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Usage: php-fastcgi {start|stop|restart}&quot;</span>
      <span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">1</span>
  <span style="color: #000000; font-weight: bold;">;;</span>
<span style="color: #000000; font-weight: bold;">esac</span>
<span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #007800;">$RETVAL</span></pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://phill84.org/2008/11/a-bash-script-to-control-spawn-fcgi-as-a-service/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

