<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: lighttpd rewrite rules for WordPress permalink</title>
	<atom:link href="http://tzangms.com/linux/1055/feed" rel="self" type="application/rss+xml" />
	<link>http://tzangms.com/linux/1055</link>
	<description></description>
	<lastBuildDate>Mon, 06 Sep 2010 03:38:39 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
	<item>
		<title>By: shami</title>
		<link>http://tzangms.com/linux/1055/comment-page-1#comment-14185</link>
		<dc:creator>shami</dc:creator>
		<pubDate>Sun, 21 Dec 2008 13:01:06 +0000</pubDate>
		<guid isPermaLink="false">http://tzangms.com/blog/lighttpd/1055#comment-14185</guid>
		<description>會想多加一個 lighttp 當前端負載是因為最近在研究 cos-html-cache 這個wp的快取插件
這個插件會產生跟每篇文章相對應的 html 檔案
例如你這篇文章是1055，就會產生一個 1055.html 檔案，網址就變成 http://tzangms.com/blog/linux/1055.html
這樣應該算是真正的靜態檔？所以我才會想是不是能讓 lighttpd 直接調用 1055.html 這個檔案，而不需要經由 nginx 執行
或許是我思路不太正確吧0.0
研究研究....</description>
		<content:encoded><![CDATA[<p>會想多加一個 lighttp 當前端負載是因為最近在研究 cos-html-cache 這個wp的快取插件<br />
這個插件會產生跟每篇文章相對應的 html 檔案<br />
例如你這篇文章是1055，就會產生一個 1055.html 檔案，網址就變成 <a href="http://tzangms.com/blog/linux/1055.html" rel="nofollow">http://tzangms.com/blog/linux/1055.html</a><br />
這樣應該算是真正的靜態檔？所以我才會想是不是能讓 lighttpd 直接調用 1055.html 這個檔案，而不需要經由 nginx 執行<br />
或許是我思路不太正確吧0.0<br />
研究研究&#8230;.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tzangms</title>
		<link>http://tzangms.com/linux/1055/comment-page-1#comment-14176</link>
		<dc:creator>tzangms</dc:creator>
		<pubDate>Sun, 21 Dec 2008 04:46:17 +0000</pubDate>
		<guid isPermaLink="false">http://tzangms.com/blog/lighttpd/1055#comment-14176</guid>
		<description>@shami
呵, 拍謝啦, 在改佈景主題, 還沒找到合適的 XD

hmm~ 應該不是這樣內, 我看你 lighttpd 的 proxy 設定部份, 應該是非靜態檔才會送到 nginx 對吧?

所以以下是我的猜測, 因為 html 被 lighttpd 當成靜態檔, 所以並不會送到 nginx, 所以 nginx 根本沒有收到, 也沒有辦法做 rewrite。 變成的狀況是, nginx 直接收到 html 的請求, 所以直接去找 html 檔, 但是沒找到, 你參考看看。

也許把 wordpress 的 permalink 不要設定為 .html</description>
		<content:encoded><![CDATA[<p>@shami<br />
呵, 拍謝啦, 在改佈景主題, 還沒找到合適的 XD</p>
<p>hmm~ 應該不是這樣內, 我看你 lighttpd 的 proxy 設定部份, 應該是非靜態檔才會送到 nginx 對吧?</p>
<p>所以以下是我的猜測, 因為 html 被 lighttpd 當成靜態檔, 所以並不會送到 nginx, 所以 nginx 根本沒有收到, 也沒有辦法做 rewrite。 變成的狀況是, nginx 直接收到 html 的請求, 所以直接去找 html 檔, 但是沒找到, 你參考看看。</p>
<p>也許把 wordpress 的 permalink 不要設定為 .html</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: shami</title>
		<link>http://tzangms.com/linux/1055/comment-page-1#comment-14173</link>
		<dc:creator>shami</dc:creator>
		<pubDate>Sun, 21 Dec 2008 03:48:44 +0000</pubDate>
		<guid isPermaLink="false">http://tzangms.com/blog/lighttpd/1055#comment-14173</guid>
		<description>把 html 拿掉這方法我有先試過，的確是可以正常運作
不過這樣就等於還是從 nginx 來執行 html 
所以我猜想可能是要在 lighttpd 寫 rewrite rules 讓他有辦法辨識 nginx 快取產生的 html 好讓 lighttpd 正常執行 html
我在摸索摸索....還是謝謝你唷

題外話...留言打字區的字好小喔....0.0</description>
		<content:encoded><![CDATA[<p>把 html 拿掉這方法我有先試過，的確是可以正常運作<br />
不過這樣就等於還是從 nginx 來執行 html<br />
所以我猜想可能是要在 lighttpd 寫 rewrite rules 讓他有辦法辨識 nginx 快取產生的 html 好讓 lighttpd 正常執行 html<br />
我在摸索摸索&#8230;.還是謝謝你唷</p>
<p>題外話&#8230;留言打字區的字好小喔&#8230;.0.0</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tzangms</title>
		<link>http://tzangms.com/linux/1055/comment-page-1#comment-14148</link>
		<dc:creator>tzangms</dc:creator>
		<pubDate>Sat, 20 Dec 2008 01:47:35 +0000</pubDate>
		<guid isPermaLink="false">http://tzangms.com/blog/lighttpd/1055#comment-14148</guid>
		<description>@shami
我沒碰過 nginx 的 rewrite 阿 ~&quot;~

不過, 看了你 lighttpd 的設定, 要不要把 html 拿掉試試看? 不知道有沒有用 ~&quot;~</description>
		<content:encoded><![CDATA[<p>@shami<br />
我沒碰過 nginx 的 rewrite 阿 ~&#8221;~</p>
<p>不過, 看了你 lighttpd 的設定, 要不要把 html 拿掉試試看? 不知道有沒有用 ~&#8221;~</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: shami</title>
		<link>http://tzangms.com/linux/1055/comment-page-1#comment-14140</link>
		<dc:creator>shami</dc:creator>
		<pubDate>Fri, 19 Dec 2008 17:12:14 +0000</pubDate>
		<guid isPermaLink="false">http://tzangms.com/blog/lighttpd/1055#comment-14140</guid>
		<description>你好..有個問題想請教你一下...
因為找不到你的留言板，所以留在此篇

我的伺服器架構是
lighttpd當前端負載 prot80 處理靜態資料→nginx當主伺服器 prot8080 處理動態資料

lighttpd的負載設定是：
$HTTP[&quot;url&quot;] !~ &quot;\.(js&#124;css&#124;gif&#124;jpg&#124;png&#124;ico&#124;txt&#124;swf&#124;htm&#124;html)$&quot; {
proxy.server  = ( &quot;&quot; =&gt; (
( &quot;host&quot; =&gt; &quot;127.0.0.1&quot;, &quot;port&quot; =&gt; 8080 )
)
)
}

rewrite rules 我是寫在nginx
location /blog/ {
index index.html index.php;
if (!-e $request_filename) {
rewrite ^/blog/(.+)$ /blog/index.php?q=$1 last;
}
}
location / {
if (-f $request_filename/index.html){
rewrite (.*) $1/index.html break;
}
if (-f $request_filename/index.php){
rewrite (.*) $1/index.php;
}
if (!-f $request_filename){
rewrite (.*) /index.php;
}
}

基本上都能正常運作，不過要進 單篇文章 就出錯了
wp的固定網址設定是： /%post_id%.html

參考了你的資料和一些國外資料都無法正常進到單篇文章
不曉得你有沒有解決的方法？</description>
		<content:encoded><![CDATA[<p>你好..有個問題想請教你一下&#8230;<br />
因為找不到你的留言板，所以留在此篇</p>
<p>我的伺服器架構是<br />
lighttpd當前端負載 prot80 處理靜態資料→nginx當主伺服器 prot8080 處理動態資料</p>
<p>lighttpd的負載設定是：<br />
$HTTP["url"] !~ &quot;\.(js|css|gif|jpg|png|ico|txt|swf|htm|html)$&quot; {<br />
proxy.server  = ( &quot;&quot; =&gt; (<br />
( &quot;host&quot; =&gt; &quot;127.0.0.1&quot;, &quot;port&quot; =&gt; 8080 )<br />
)<br />
)<br />
}</p>
<p>rewrite rules 我是寫在nginx<br />
location /blog/ {<br />
index index.html index.php;<br />
if (!-e $request_filename) {<br />
rewrite ^/blog/(.+)$ /blog/index.php?q=$1 last;<br />
}<br />
}<br />
location / {<br />
if (-f $request_filename/index.html){<br />
rewrite (.*) $1/index.html break;<br />
}<br />
if (-f $request_filename/index.php){<br />
rewrite (.*) $1/index.php;<br />
}<br />
if (!-f $request_filename){<br />
rewrite (.*) /index.php;<br />
}<br />
}</p>
<p>基本上都能正常運作，不過要進 單篇文章 就出錯了<br />
wp的固定網址設定是： /%post_id%.html</p>
<p>參考了你的資料和一些國外資料都無法正常進到單篇文章<br />
不曉得你有沒有解決的方法？</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: [FreeBSD]Lighttpd + php5 + 解決 wordpress Permalinks mod_write &#124; 小惡魔 - 電腦技術 - 生活日記 - 美食介紹 - AppleBOY</title>
		<link>http://tzangms.com/linux/1055/comment-page-1#comment-12810</link>
		<dc:creator>[FreeBSD]Lighttpd + php5 + 解決 wordpress Permalinks mod_write &#124; 小惡魔 - 電腦技術 - 生活日記 - 美食介紹 - AppleBOY</dc:creator>
		<pubDate>Thu, 03 Jul 2008 08:58:05 +0000</pubDate>
		<guid isPermaLink="false">http://tzangms.com/blog/lighttpd/1055#comment-12810</guid>
		<description>[...] Installing Lighttpd With PHP5 And MySQL Support On CentOS 5.0  Lighttpd-輕量級 Web Server gslin 大大：在 lighttpd 上擋圖片盜連 Lighttpd 防止圖片盜連 lighttpd rewrite rules for Wordpress permalink [...]</description>
		<content:encoded><![CDATA[<p>[...] Installing Lighttpd With PHP5 And MySQL Support On CentOS 5.0  Lighttpd-輕量級 Web Server gslin 大大：在 lighttpd 上擋圖片盜連 Lighttpd 防止圖片盜連 lighttpd rewrite rules for WordPress permalink [...]</p>
]]></content:encoded>
	</item>
</channel>
</rss>
