<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="th">
	<id>http://158.108.32.49/wiki/index.php?action=history&amp;feed=atom&amp;title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553%2F%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3</id>
	<title>418342 ภาคปลาย 2553/การบ้าน 3 - ประวัติรุ่นแก้ไข</title>
	<link rel="self" type="application/atom+xml" href="http://158.108.32.49/wiki/index.php?action=history&amp;feed=atom&amp;title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553%2F%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3"/>
	<link rel="alternate" type="text/html" href="http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;action=history"/>
	<updated>2026-05-06T16:52:11Z</updated>
	<subtitle>ประวัติรุ่นแก้ไขของหน้านี้ในวิกิ</subtitle>
	<generator>MediaWiki 1.33.1</generator>
	<entry>
		<id>http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;diff=10786&amp;oldid=prev</id>
		<title>Ckw เมื่อ 08:18, 16 มีนาคม 2554</title>
		<link rel="alternate" type="text/html" href="http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;diff=10786&amp;oldid=prev"/>
		<updated>2011-03-16T08:18:25Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;th&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;←รุ่นแก้ไขก่อนหน้า&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;รุ่นแก้ไขเมื่อ 08:18, 16 มีนาคม 2554&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot; &gt;แถว 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;แถว 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt;−&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;ให้ไว้เมื่อวันที่ 17 กุมภาพันธ์ 2554 ส่ง&amp;#039;&amp;#039;&amp;#039;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;วันพุธที่ 16 &lt;/del&gt;มีนาคม 2554 เวลา &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;12&lt;/del&gt;.59 น.&amp;#039;&amp;#039;&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;ให้ไว้เมื่อวันที่ 17 กุมภาพันธ์ 2554 ส่ง&amp;#039;&amp;#039;&amp;#039;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;วันพฤหัสบดีที่ 17 &lt;/ins&gt;มีนาคม 2554 เวลา &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;23&lt;/ins&gt;.59 น.&amp;#039;&amp;#039;&amp;#039; &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;(เลื่อนจากเดิมคือวันพุธที่ 16 มีนาคม 2554)&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;ในการบ้านนี้เราจะทำการสร้างระบบบล็อกเบื้องต้นที่มีฟีเจอร์ดังต่อไปนี้&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;ในการบ้านนี้เราจะทำการสร้างระบบบล็อกเบื้องต้นที่มีฟีเจอร์ดังต่อไปนี้&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Ckw</name></author>
		
	</entry>
	<entry>
		<id>http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;diff=10722&amp;oldid=prev</id>
		<title>Cardcaptor: /* เริ่มต้น */</title>
		<link rel="alternate" type="text/html" href="http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;diff=10722&amp;oldid=prev"/>
		<updated>2011-02-23T10:01:52Z</updated>

		<summary type="html">&lt;p&gt;&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;เริ่มต้น&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;th&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;←รุ่นแก้ไขก่อนหน้า&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;รุ่นแก้ไขเมื่อ 10:01, 23 กุมภาพันธ์ 2554&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l13&quot; &gt;แถว 13:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;แถว 13:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* ให้ลงไลบรารี [http://maruku.rubyforge.org/index.html Maruku] ซึ่งเป็นตัวแปรภาษา Makrdown ที่เราจะใช้ในการเขียนเนื้อหาของบล็อก ด้วยการสั่ง&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* ให้ลงไลบรารี [http://maruku.rubyforge.org/index.html Maruku] ซึ่งเป็นตัวแปรภาษา Makrdown ที่เราจะใช้ในการเขียนเนื้อหาของบล็อก ด้วยการสั่ง&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  gem install maruku&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  gem install maruku&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;* Rails 2.x มีการสั่งรัน server ที่แตกต่างไปจาก Rails 3 กล่าวคือ เราต้องสั่งด้วยคำสั่ง&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt; ruby script/server&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;แทนที่จะสั่ง rails server ตามเดิม&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== ฐานข้อมูล ==&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== ฐานข้อมูล ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Cardcaptor</name></author>
		
	</entry>
	<entry>
		<id>http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;diff=10709&amp;oldid=prev</id>
		<title>Cardcaptor เมื่อ 17:39, 16 กุมภาพันธ์ 2554</title>
		<link rel="alternate" type="text/html" href="http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;diff=10709&amp;oldid=prev"/>
		<updated>2011-02-16T17:39:51Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;th&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;←รุ่นแก้ไขก่อนหน้า&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;รุ่นแก้ไขเมื่อ 17:39, 16 กุมภาพันธ์ 2554&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot; &gt;แถว 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;แถว 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;ให้ไว้เมื่อวันที่ 17 กุมภาพันธ์ 2554 ส่ง&amp;#039;&amp;#039;&amp;#039;วันพุธที่ 16 มีนาคม 2554 เวลา 12.59 น.&amp;#039;&amp;#039;&amp;#039;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt;+&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;ในการบ้านนี้เราจะทำการสร้างระบบบล็อกเบื้องต้นที่มีฟีเจอร์ดังต่อไปนี้&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;ในการบ้านนี้เราจะทำการสร้างระบบบล็อกเบื้องต้นที่มีฟีเจอร์ดังต่อไปนี้&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* มีหน้าหลักแสดงโพสต์ล่าสุด&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* มีหน้าหลักแสดงโพสต์ล่าสุด&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Cardcaptor</name></author>
		
	</entry>
	<entry>
		<id>http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;diff=10708&amp;oldid=prev</id>
		<title>Cardcaptor: /* หัวข้อ */</title>
		<link rel="alternate" type="text/html" href="http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;diff=10708&amp;oldid=prev"/>
		<updated>2011-02-16T17:38:18Z</updated>

		<summary type="html">&lt;p&gt;&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;หัวข้อ&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;th&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;←รุ่นแก้ไขก่อนหน้า&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;รุ่นแก้ไขเมื่อ 17:38, 16 กุมภาพันธ์ 2554&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l200&quot; &gt;แถว 200:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;แถว 200:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== ส่งงาน ==&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== ส่งงาน ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#039;&amp;#039;&amp;#039;หลังจากทำการพัฒนาเสร็จแล้ว ให้ rollback migration ทั้งหมด (ให้ database ว่าง) แล้ว zip ไดเรคทอรีที่ rails สร้างทั้งหมดส่งมาที่อีเมล์ของ อ.ประมุข (pramook at gmail dot com) และ อ.ชาคริต (chakrit dot w at gmail dot com)&amp;#039;&amp;#039;&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;td class=&#039;diff-marker&#039;&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#039;&amp;#039;&amp;#039;หลังจากทำการพัฒนาเสร็จแล้ว ให้ rollback migration ทั้งหมด (ให้ database ว่าง) แล้ว zip ไดเรคทอรีที่ rails สร้างทั้งหมดส่งมาที่อีเมล์ของ อ.ประมุข (pramook at gmail dot com) และ อ.ชาคริต (chakrit dot w at gmail dot com)&amp;#039;&amp;#039;&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt;−&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&#039;diff-marker&#039;&gt;−&lt;/td&gt;&lt;td style=&quot;color: #222; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;== หัวข้อ ==&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Cardcaptor</name></author>
		
	</entry>
	<entry>
		<id>http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;diff=10707&amp;oldid=prev</id>
		<title>Cardcaptor: หน้าที่ถูกสร้างด้วย &#039;ในการบ้านนี้เราจะทำการสร้างระบบบล็อกเบื้องต้นท…&#039;</title>
		<link rel="alternate" type="text/html" href="http://158.108.32.49/wiki/index.php?title=418342_%E0%B8%A0%E0%B8%B2%E0%B8%84%E0%B8%9B%E0%B8%A5%E0%B8%B2%E0%B8%A2_2553/%E0%B8%81%E0%B8%B2%E0%B8%A3%E0%B8%9A%E0%B9%89%E0%B8%B2%E0%B8%99_3&amp;diff=10707&amp;oldid=prev"/>
		<updated>2011-02-16T17:37:52Z</updated>

		<summary type="html">&lt;p&gt;หน้าที่ถูกสร้างด้วย &amp;#039;ในการบ้านนี้เราจะทำการสร้างระบบบล็อกเบื้องต้นท…&amp;#039;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;หน้าใหม่&lt;/b&gt;&lt;/p&gt;&lt;div&gt;ในการบ้านนี้เราจะทำการสร้างระบบบล็อกเบื้องต้นที่มีฟีเจอร์ดังต่อไปนี้&lt;br /&gt;
* มีหน้าหลักแสดงโพสต์ล่าสุด&lt;br /&gt;
* มีระบบให้ผู้อ่านมาพิมพ์คอมเมนต์&lt;br /&gt;
* ผู้เขียนสามารถตั้งค่าต่างๆ ของบล็อก เช่น ชื่อบล็อก, จำนวนโพสต์ที่แสดงในแต่ละหน้า, ฯลฯ&lt;br /&gt;
* ผู้เขียนสามารถแท็กบทความต่างๆ ได้&lt;br /&gt;
&lt;br /&gt;
== เริ่มต้น ==&lt;br /&gt;
* เนื้อหาของการบ้านนี้เขียนด้วย Rails 2.3.4 ดังนั้น ก่อนรันจะต้องลงมันโดยสั่ง&lt;br /&gt;
 gem install rails -v 2.3.4&lt;br /&gt;
* ให้ดาวน์โหลดโค้ดเริ่มต้นจาก http://theory.cpe.ku.ac.th/~pramook/418342/homework-03/homework-03-starter.zip ในโค้ดเริ่มต้นนี้จะมี scaffold ซึ่งสร้างตามฐานข้อมูลที่เขียนไว้ข้างล่าง พร้อมกับข้อมูลทดสอบส่วนหนึ่งอยู่&lt;br /&gt;
* ให้ลงไลบรารี [http://maruku.rubyforge.org/index.html Maruku] ซึ่งเป็นตัวแปรภาษา Makrdown ที่เราจะใช้ในการเขียนเนื้อหาของบล็อก ด้วยการสั่ง&lt;br /&gt;
 gem install maruku&lt;br /&gt;
&lt;br /&gt;
== ฐานข้อมูล ==&lt;br /&gt;
ฐานข้อมูลของระบบบล็อกจะประกอบด้วยตารางต่อไปนี้&lt;br /&gt;
=== ตาราง posts ===&lt;br /&gt;
เก็บโพสต์ของเจ้าของบล็อก มีฟีลด์ดังต่อไปนี้&lt;br /&gt;
* title เป็น string&lt;br /&gt;
* content เป็น text ซึ่งเขียนด้วยภาษา [http://daringfireball.net/projects/markdown/ Markdown]&lt;br /&gt;
* published_at เป็น datetime ซึ่งจะมีค่าเป็น nil ถ้าหากผู้ใช้ยังไม่ได้ตีพิมพ์โพสต์นี้&lt;br /&gt;
* timestamp (created_at และ modified_at) ซึ่งสร้างด้วย t.timestamp ใน migration&lt;br /&gt;
=== ตาราง comments ===&lt;br /&gt;
เก็บคอมเมนต์ที่มีคนมาเขียน มีฟีลด์ดังต่อไปนี้&lt;br /&gt;
* name เป็น string เก็บชื่อคนเขียน comment&lt;br /&gt;
* email เป็น string เก็บ email ของคนเขียน comment&lt;br /&gt;
* url เป็น string เก็บ URL ของเว็บไซต์ของคนเขียน comment&lt;br /&gt;
* content เป็น text ซึ่งเขียนด้วยภาษา Markdown เช่นกัน&lt;br /&gt;
* post_id เป็น integer ซึ่งเก็บ id ของ post ที่ comment &lt;br /&gt;
* timestamp (created_at และ modified_at) ซึ่งสร้างด้วย t.timestamp ใน migration&lt;br /&gt;
=== ตาราง tags ===&lt;br /&gt;
เก็็บ tag ต่างๆ มีฟีลด์ดังต่อไปนี้&lt;br /&gt;
* name เป็น string ซึ่งเป็นชื่อของ tag&lt;br /&gt;
=== ตาราง posts_tags ===&lt;br /&gt;
ใช้ในการทำความสัมพันธ์แบบ many-to-many ระหว่าง post กับ tag มีฟีลด์ดังต่อไปนี้&lt;br /&gt;
* post_id&lt;br /&gt;
* tag_id&lt;br /&gt;
=== ตาราง settings ===&lt;br /&gt;
เก็บค่าต่างๆ ที่ผู้ใช้สามารถกำหนดให้บล็อกได้ เช่น ชื่อบล็อก ฯลฯ มีฟีลด์ดังต่อไปนี้&lt;br /&gt;
* name เป็น string ซึ่งเป็นชื่อของค่าที่ผู้ใช้กำหนดได้&lt;br /&gt;
* value เป็น string ซึ่งเก็บค่าจริง&lt;br /&gt;
ในตาราง settings จะมีค่าต่อไปนี้อยู่&lt;br /&gt;
* blog_name = ชื่อของบล็อก (จะปรากฏอยู่ที่หัวเว็บเพจ)&lt;br /&gt;
* blog_subtitle = คำอธิบายบล็อกสั้นๆ (จะปรากฏอยู่ที่หัวเว็บเพจเช่นกัน)&lt;br /&gt;
* blog_url = URL ของบล็อกซึ่งมีไว้ใช้ทำ RSS feed&lt;br /&gt;
* posts_per_page = จำนวนบล็อกในแต่ละหน้า&lt;br /&gt;
* comment_count = จำนวนคอมเมนต์เริ่มต้นที่แสดงเวลาดูโพสต์&lt;br /&gt;
&lt;br /&gt;
== การบ้านข้อ 1: แก้ไขโมเดล ==&lt;br /&gt;
=== แก้ไข Post ===&lt;br /&gt;
# ทำให้ Post มีความสัมพันธ์แบบ many-to-many กับ Tag&lt;br /&gt;
# ทำให้ Post มีความสัมพันธ์แบบ many-to-one กับ Comment&lt;br /&gt;
# เขียน validation ทำให้ Post สอดคล้องกับเงื่อนไขต่อไปนี้&lt;br /&gt;
#* title จะต้องไม่ว่างเปล่า&lt;br /&gt;
#* content จะต้องไม่ว่างเปล่า&lt;br /&gt;
# เขียนเมธอดชื่อ published? เพื่อเช็คว่าผู้ใช้ได้ตีพิมพ์โพสต์ไปแล้วหรือยัง โดย method จะเช็คว่า published_at มีค่าเป็น nil หรือไม่ ถ้าใช่แสดงว่ายังไม่ได้ตีพิมพ์&lt;br /&gt;
&lt;br /&gt;
เมื่อคุณแก้โค้ดตามนี้แล้ว ให้ลองรัน&lt;br /&gt;
 rake test:units TEST=unit/test/post_test.rb&lt;br /&gt;
เพื่อตรวจสอบว่าได้แก้ไขไปถูกต้องแล้วหรือไม่&lt;br /&gt;
&lt;br /&gt;
=== แก้ไข Comment ===&lt;br /&gt;
เขียน validation ทำให้ Comment สอดคล้องกับเงื่อนไขต่อไปนี้&lt;br /&gt;
* name จะต้องไม่ว่างเปล่า&lt;br /&gt;
* email จะต้องมีรูปแบบเหมือน email ​(ใบ้: ใช้ validate_format_of)&lt;br /&gt;
* url จะต้องมีรูปแบบเหมือน URL จริงๆ (คือ http://something.someone.org/abc/def) (ใบ้: ไปหา regular expression มาจากใน net)&lt;br /&gt;
* content จะต้องไม่ว่างเปล่า&lt;br /&gt;
เมื่อคุณแก้โค้ดตามนี้แล้ว ให้ลองรัน&lt;br /&gt;
 rake test:units TEST=unit/test/comment_test.rb&lt;br /&gt;
เพื่อตรวจสอบว่าได้แก้ไขไปถูกต้องแล้วหรือไม่&lt;br /&gt;
&lt;br /&gt;
=== แก้ไข Tag ===&lt;br /&gt;
==== เขียน validation ====&lt;br /&gt;
ทำให้ Tag ที่มีรูปแบบถูกต้องทุกตัวสอดคล้องกับเงื่อนไขต่อไปนี้ &lt;br /&gt;
* name จะต้องไม่ว่างเปล่า&lt;br /&gt;
* ใน name จะต้องไม่มีเครื่องหมายคอมมา (,) อยู่ภายใน (เนื่องจากเราใจใช้เครื่องหมายนี้ในการแยก tag ต่างๆ ออกจากกัน) กล่าวคือ &amp;quot;space adventure&amp;quot; ใช้ได้ แต่ &amp;quot;space,adventure&amp;quot; หรือ &amp;quot;space, adventure&amp;quot; ใช้ไม่ได้&lt;br /&gt;
&lt;br /&gt;
==== ทำให้ชื่อ Tag อยู่ในรูป &amp;quot;ปกติ&amp;quot; ====&lt;br /&gt;
เราต้องการให้เวลาเจ้าของบล็อกใส่ tag ให้โพสต์ แล้วเขาสามารถพิมพ์ &amp;quot;life, space adventure, computer &amp;amp;nbsp;&amp;amp;nbsp;security &amp;quot; แล้วระบบสามารถที่จะแยกมันออกเป็น 3 tag ได้แก่ &amp;quot;life&amp;quot;, &amp;quot;space adventure&amp;quot;, และ &amp;quot;computer security&amp;quot; ให้โดยอัตโนมัติ&lt;br /&gt;
&lt;br /&gt;
เนื่องจากเราบอกว่าชื่อแท็กจะต้องไม่มีเครื่องหมายคอมมาอยู่ข้างใน ดังนั้นเราสามารถแยก string ที่ผู้ใช้ให้มาข้างบนเป็นสามส่วนคือ &amp;quot;life&amp;quot; และ &amp;quot; space adventure&amp;quot; และ &amp;quot; computer &amp;amp;nbsp;&amp;amp;nbsp;security &amp;quot;&lt;br /&gt;
&lt;br /&gt;
เวลาเราเก็บชื่อของ Tag ใน database เราต้องการกำจัดข้อมูลที่ไม่สำคัญออกจากชื่อ Tag ที่ผู้ใช้ป้อนมาไป ยกตัวอย่างเช่น ผู้ใช้ป้อน &amp;quot; computer &amp;amp;nbsp;&amp;amp;nbsp;security &amp;quot; ซึ่งมีช่องว่างอยู่ข้างหน้าชื่อ ข้างหลังชื่อ และช่องว่างระหว่างคำว่า computer กับคำว่า security มีอยู่ถึงสามตัว แต่ในเวลาเก็บข้อมูลเราต้องการให้ชื่อมีค่าเท่ากับ &amp;quot;computer security&amp;quot; เท่านั้น กล่าวคือ&lt;br /&gt;
* จะต้องไม่มีช่องว่างนำหน้าชื่อ Tag&lt;br /&gt;
* จะต้องไม่มีช่องว่างตามหลังชื่อ Tag&lt;br /&gt;
* ระหว่างคำสองคำที่อยู่ข้างๆ กันในชื่อ Tag จะมีช่องว่างคั่นได้เพียงช่องเดียวเท่านั้น&lt;br /&gt;
เราเรียกชื่อที่สอดคล้องกับกฎทั้งสามข้อข้างต้นว่าเป็นชื่อ Tag ในรูป &amp;quot;ปกติ&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==== ตรวจสอบความถูกต้อง ====&lt;br /&gt;
จงเพิ่มคลาสเมธอด normalize_name(given_name) ในคลาส Tag โดยที่เมธอดนี้ืคืนค่าของ given_name เมื่อทำให้มันอยู่ในรูปปกติแล้ว&lt;br /&gt;
&lt;br /&gt;
เวลาประกาศคลาสเมธอดให้ประกาศเช่นนี้&lt;br /&gt;
&amp;lt;geshi lang=&amp;quot;rails&amp;quot;&amp;gt;&lt;br /&gt;
class Tag&lt;br /&gt;
  ...&lt;br /&gt;
&lt;br /&gt;
  def Tag.normalize_name(given_name)&lt;br /&gt;
    ...&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
  ...&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/geshi&amp;gt;&lt;br /&gt;
&lt;br /&gt;
เมื่อคุณแก้โค้ดตามนี้แล้ว ให้ลองรัน&lt;br /&gt;
 rake test:units TEST=unit/test/tag_test.rb&lt;br /&gt;
เพื่อตรวจสอบว่าได้แก้ไขไปถูกต้องแล้วหรือไม่&lt;br /&gt;
&lt;br /&gt;
=== แก้ไข Setting ===&lt;br /&gt;
จงเขียน validation เพื่อทำให้ Setting ทุกตัวสอดคล้องกับเงื่อนไขต่อไปนี้&lt;br /&gt;
* name จะต้องไม่เป็นค่าว่าง&lt;br /&gt;
* value จะต้องไม่เป็นค่าว่าง&lt;br /&gt;
* ถ้า name มีค่าเท่ากับ &amp;quot;posts_per_page&amp;quot; หรือ ​&amp;quot;comment_count&amp;quot; แล้ว value จะต้องเป็นสตริงที่มีค่าเป็นตัวเลข&lt;br /&gt;
&lt;br /&gt;
เมื่อคุณแก้โค้ดตามนี้แล้ว ให้ลองรัน&lt;br /&gt;
 rake test:units TEST=unit/test/setting_test.rb&lt;br /&gt;
เพื่อตรวจสอบว่าได้แก้ไขไปถูกต้องแล้วหรือไม่&lt;br /&gt;
&lt;br /&gt;
== การบ้านข้อ 2: ทำให้ Markdown ใช้ได้ ==&lt;br /&gt;
=== แก้ไข Post ===&lt;br /&gt;
ให้สร้างเมธอดชื่อ markdowned_content ซึ่งคืนค่า content ที่ถูกแปลด้วยภาษา Markdown แล้ว ในการแปลให้ใช้ไลบรารีชื่อ Maruku ซึ่งมีวิธีใช้บอกอยู่ในเอกสารนี้ http://maruku.rubyforge.org/usage.html&lt;br /&gt;
&lt;br /&gt;
เมื่อคุณแก้โค้ดตามนี้แล้ว ให้ลองรัน&lt;br /&gt;
 rake test:units TEST=unit/test/markdown_post_test.rb&lt;br /&gt;
เพื่อตรวจสอบว่าได้แก้ไขไปถูกต้องแล้วหรือไม่&lt;br /&gt;
&lt;br /&gt;
=== แก้ไข Comment ===&lt;br /&gt;
สำหรับโมเดล Comment ก็ให้สร้างเมธอดชื่อ markdowned_content ซึ่งทำงานเช่นเดียวกันกับ markdowned_content ของ Post เช่นกัน&lt;br /&gt;
&lt;br /&gt;
เมื่อคุณแก้โค้ดตามนี้แล้ว ให้ลองรัน&lt;br /&gt;
 rake test:units TEST=unit/test/markdown_comment_test.rb&lt;br /&gt;
เพื่อตรวจสอบว่าได้แก้ไขไปถูกต้องแล้วหรือไม่&lt;br /&gt;
&lt;br /&gt;
== การบ้านข้อ 3: แก้ Post Controller และ View ที่เกี่ยวข้อง ==&lt;br /&gt;
=== แก้ show ของ PostsController ===&lt;br /&gt;
ให้เปลี่ยน app/views/posts/show.html.erb ให้เขียนโค้ด HTML ที่มีการแสดงข้อมูลต่อไปนี้&lt;br /&gt;
* หัวเรื่องของโพสต์&lt;br /&gt;
* เนื้อหาโพสต์&lt;br /&gt;
* วันที่เขียน&lt;br /&gt;
* แท็กต่างๆ ของโพสต์&lt;br /&gt;
* ลิงค์ Edit และ Back ที่ได้มาจาก scaffold&lt;br /&gt;
* จำนวนคอมเมนต์&lt;br /&gt;
* คอมเมนต์เรียงจากเก่าไปใหม่&lt;br /&gt;
* แบบฟอร์มสำหรับให้ผู้ใช้กรอกคอมเมนต์&lt;br /&gt;
&lt;br /&gt;
จงทำให้แบบฟอร์มในการกรอกคอมเมนต์นี้ทำงานได้ถูกต้อง&lt;br /&gt;
&lt;br /&gt;
=== แก้ไข index ของ PostsController ===&lt;br /&gt;
ให้เปลี่ยน app/views/posts/index.html.erb ให้เขียนโค้ด HTML ทีมีการแสดงข้อมูลดังนี้&lt;br /&gt;
* แสดงโพสต์ใหม่ล่าสุดเท่ากับจำนวน posts_per_page ที่เก็บไว้ใน Setting&lt;br /&gt;
* สำหรับแต่ละโพสต์ ให้มีการแสดง&lt;br /&gt;
** วันที่เขียน&lt;br /&gt;
** หัวเรื่อง ซึ่งมีลิงค์ไปยังหน้า show ของโพสต์นั้น&lt;br /&gt;
** เนื้อหาโพสต์&lt;br /&gt;
** แท็กต่างๆ ของโพสต์&lt;br /&gt;
** จำนวนคอมเมนต์ ซึ่งมีลิงค์ไปยังหน้า show ของโพสต์นั้น แต่เมื่อตามลิงค์ไปแล้วให้ไปอยู่ตรงที่ตำแหน่งเริ่มคอมเมนต์พอดี&lt;br /&gt;
** ลิงค์ Edit และ Delete ที่ได้มาจาก scaffold&lt;br /&gt;
&lt;br /&gt;
ในการแสดงโพสต์ใหม่ล่าสุดนี้ คุณจะต้องแสดง&lt;br /&gt;
* โพสต์ที่ published_at มีค่าไม่เป็นค่าว่าง&lt;br /&gt;
* เรียงโพสต์ตาม published_at จากใหม่สุดไปยังเก่าสุด&lt;br /&gt;
* มีลิงค์ให้ผู้ใช้คลิกเพื่ออ่านโพสต์เก่าขึ้นหรือไม่ขึ้นที่อยู่ในหน้าถัดไป (เหมือนบล็อกทั่วๆ ไป)&lt;br /&gt;
&lt;br /&gt;
=== เพิ่ม action &amp;quot;admin&amp;quot; ของ PostController ===&lt;br /&gt;
ให้เขียน action ชื่อ admin โดยที่เมื่อผู้ใช้เข้าไปยัง url /posts/admin แล้วจะเจอหน้าเว็บซึ่งมีลักษณะคล้ายๆ กับหน้า index ที่ scaffold สร้างมาให้ กล่าวคือ&lt;br /&gt;
* มีการแสดงโพสต์เป็นตาราง แทนที่จะเป็นมีแต่ละโพสต์ไปเหมือนกับหน้า index โดยที่แต่ละแถวของตารางจะตรงกับโพสต์หนึ่งโพสต์ และการเรียงโพสต์ให้เรียงตาม modified_at&lt;br /&gt;
* สำหรับตารางแต่ละแถว&lt;br /&gt;
** ไม่ต้องมีการแสดงเนื้อหาโพสต์&lt;br /&gt;
** มีการแสดงจำนวน comment&lt;br /&gt;
** มีการแสดง tag ทั้งหมดของโพสต์ พร้อมกับลิงค์ไปยังหน้าของ tag นั้น&lt;br /&gt;
** มีการแสดงเวลาที่ผู้ใช้ตีพิมพ์โพสต์ &lt;br /&gt;
** มีลิงค์ไปยังหน้า show ของโพสต์นั้น&lt;br /&gt;
** มีลิงค์สำหรับลบโพสต์&lt;br /&gt;
** มีลิงค์สำหรับให้ผู้ใช้ซ่อนบทความที่ติพิมพ์ไปแล้ว (unpublish) เมื่อคลิกลิงค์นี้ มันจะทำให้ published_at ของโพสต์นั้นมีค่าเป็นค่าว่าง&lt;br /&gt;
&lt;br /&gt;
=== แก้ไข edit ของ PostsController ===&lt;br /&gt;
ให้ทำการ&lt;br /&gt;
* ลบ input สำหรับให้กรอก published_at ออก&lt;br /&gt;
* เพิ่ม input ชนิด text สำหรับกรอก tag ต่างๆ กล่าวคือถ้าผู้ใช้กรอก &amp;quot;dog, sea otter, cat&amp;quot; แล้วส่งแบบฟอร์มมา ให้ระบบทำการตัดคำและทำให้โพสต์มี tag สามแท็กคือ dog และ sea otter และ cat&lt;br /&gt;
* ทำให้ปุ่ม submit ของฟอร์มมีอยู่สามปุ่ม ได้แก่&lt;br /&gt;
** &amp;quot;Save Draft&amp;quot; ซึ่งทำการส่งฟอร์มธรรมดา แต่ยังไม่ได้ทำให้โพสต์ที่เขียนถูกตีพิมพ์ เมื่อส่งฟอร์มสำเร็จให้ redirect ไปหน้า admin&lt;br /&gt;
** &amp;quot;Save and Continue Editing&amp;quot; ซึ่งทำการส่งฟอร์ม แต่ยังไม่ได้ทำให้โพสต์ที่เขียนถูกตีพิมพ์ เมื่อส่งฟอร์มสำเร็จแล้วให้กลับมายังหน้าเดิม&lt;br /&gt;
** &amp;quot;Publish&amp;quot; ซึ่งทำการส่งฟอร์ม และทำให้ค่า published_at ของโพสต์มีค่าเท่ากับเวลาปัจจุนัน เมื่อส่งฟอร์มสำเร็จแล้วให้ redirect ไปหน้า index&lt;br /&gt;
&lt;br /&gt;
== การบ้านข้อ 4: แก้ไข CommentsController และ View ที่เกี่ยวข้อง ==&lt;br /&gt;
=== แก้ไขหน้า index ===&lt;br /&gt;
* ทำหน้า index ให้มีการแสดงคอมเมนต์จากใหม่ไปยังเก่า&lt;br /&gt;
* สำหรับคอมเมนต์แต่ละคอมเมนต์ให้แสดง&lt;br /&gt;
** ชื่อและลิงค์ไปยังเว็บไซต์ของผู้เขียน&lt;br /&gt;
** เนื้อหาที่ถูกแปลด้วยภาษา Markdown แล้ว&lt;br /&gt;
** โพสต์ที่คอมเมนต์นี้ผูกอยู่&lt;br /&gt;
&lt;br /&gt;
ในการแสดงนี้ ตอนแรกให้แสดงคอมเมนต์เท่ากับจำนวน comment_count ที่เก็บไว้ใน Setting และที่ส่วนล่างสุดของหน้าให้มีลิงค์ &amp;quot;Read more comments&amp;quot; ซึ่งเมื่อคลิกแล้วจะมีการส่ง Ajax request ไปเพื่อดึงคอมเมนต์อีกจำนวน comment_count ตัวมาแสดงต่อจากที่มีไปแล้วโดยไม่มีการ reload หน้าใหม่&lt;br /&gt;
&lt;br /&gt;
== การบ้านข้อ 5: แก้ไข TagsController และ View ที่เกี่ยวข้อง ==&lt;br /&gt;
=== แก้ไขหน้า show ===&lt;br /&gt;
ทำให้หน้า show มีการแสดงโพสต์ทั้งหมดทีี่ีมี tag นั้น โดยการแสดงผลจะมีลักษณะคล้ายกับหน้า index ของ Post คือจะแสดงเป็นโพสต์ไปพร้อมเนื้อหา การแสดงผลจะไม่อยู่ในรูปแบบตารางเหมือนกับที่ scaffold สร้างมาให้&lt;br /&gt;
&lt;br /&gt;
ในการแสดงนี้ ตอนแรกให้แสดงโพสต์เท่ากับจำนวน posts_per_page ที่เก็บไว้ใน Setting และที่ส่วนล่างสุดของหน้าให้มีลิงค์ &amp;quot;Read more comments&amp;quot; ซึ่งเมื่อคลิกแล้วจะมีการส่ง Ajax request ไปเพื่อดึงคอมเมนต์อีกจำนวน posts_per_page ตัวมาแสดงต่อจากที่มีไปแล้วโดยไม่มีการ reload หน้าใหม่&lt;br /&gt;
&lt;br /&gt;
== ส่งงาน ==&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;หลังจากทำการพัฒนาเสร็จแล้ว ให้ rollback migration ทั้งหมด (ให้ database ว่าง) แล้ว zip ไดเรคทอรีที่ rails สร้างทั้งหมดส่งมาที่อีเมล์ของ อ.ประมุข (pramook at gmail dot com) และ อ.ชาคริต (chakrit dot w at gmail dot com)&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
== หัวข้อ ==&lt;/div&gt;</summary>
		<author><name>Cardcaptor</name></author>
		
	</entry>
</feed>