<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>We are Mr and Ms ITs</title>
	<atom:link href="http://wmits.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://wmits.wordpress.com</link>
	<description></description>
	<lastBuildDate>Mon, 20 Jun 2011 15:49:50 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='wmits.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>We are Mr and Ms ITs</title>
		<link>http://wmits.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://wmits.wordpress.com/osd.xml" title="We are Mr and Ms ITs" />
	<atom:link rel='hub' href='http://wmits.wordpress.com/?pushpress=hub'/>
		<item>
		<title>Phần 2 &#8211; Function trong JavaScript</title>
		<link>http://wmits.wordpress.com/2009/10/19/ph%e1%ba%a7n-2-function-trong-javascript/</link>
		<comments>http://wmits.wordpress.com/2009/10/19/ph%e1%ba%a7n-2-function-trong-javascript/#comments</comments>
		<pubDate>Mon, 19 Oct 2009 12:49:28 +0000</pubDate>
		<dc:creator>honpham</dc:creator>
				<category><![CDATA[JavaScript]]></category>

		<guid isPermaLink="false">http://wmits.wordpress.com/?p=247</guid>
		<description><![CDATA[Một function trong JavaScript dùng để viết 1 method hoặc dùng làm constructor để khởi tại một class mới. Cách dùng object làm thuộc tính giống như java. Một function trong JavaScript có thể có hoặc không trả về giá trị. Dùng return gia_tri_tra_ve để trả về giá trị. Function như một constructor function Employee(name, [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=247&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Một function trong JavaScript dùng để viết 1 <em>method</em> hoặc dùng làm <em>constructor</em> để khởi tại một class mới. Cách dùng object làm thuộc tính giống như java.</p>
<p>Một function trong JavaScript có thể có hoặc không trả về giá trị.</p>
<p>Dùng <em>return gia_tri_tra_ve</em> để trả về giá trị.</p>
<p>Function như một constructor</p>
<p><strong>function</strong> Employee(name, age, hometown) {</p>
<p><strong>this</strong>.name = name;</p>
<p><strong>this</strong>.age = age;</p>
<p><strong>this</strong>.hometown = hometown;</p>
<p>}</p>
<p>Function như một method</p>
<p><strong>function</strong> viewName(employee) {</p>
<p>document.write(employee.name + &#8221; &#8211; &#8221; + employee.hometown);</p>
<p>}</p>
<p>Function là method và trả về giá trị</p>
<p><strong>function</strong> plug(number1, number2) {</p>
<p>return number1 + number2;</p>
<p>}</p>
<p>Áp dụng function làm constructor và làm method</p>
<p>Trong file *.js</p>
<p><strong>function</strong> Owner(name, sex, pet) {</p>
<p><strong>this</strong>.name = name;</p>
<p><strong>this</strong>.sex = sex;</p>
<p><strong>this</strong>.pet = pet;</p>
<p>}</p>
<p><strong>function</strong> Pet(type, colorFeather) {</p>
<p><strong>this</strong>.type = type;</p>
<p><strong>this</strong>.colorFeather = colorFeather;</p>
<p>}</p>
<p><strong>function</strong> viewOwner(owner) {</p>
<p>return owner.name + &#8221; is owner of &#8221; + owner.pet.type;</p>
<p>}</p>
<p>Sử dụng:</p>
<p>&lt;script language=&#8221;javascript&#8221;&gt;</p>
<p>document.write(&#8220;result of 4 + 5 = &#8221; + plug(4, 5));</p>
<p>var dog = new Pet(&#8220;dog&#8221;, &#8220;black&#8221;);</p>
<p>var hon = new Owner(&#8220;hon pham&#8221;, &#8220;female&#8221;, dog);</p>
<p>document.write(&#8220;&lt;br/&gt;&#8221;);</p>
<p>document.write(viewOwner(hon));</p>
<p>&lt;/script&gt;</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wmits.wordpress.com/247/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wmits.wordpress.com/247/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wmits.wordpress.com/247/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wmits.wordpress.com/247/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wmits.wordpress.com/247/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wmits.wordpress.com/247/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wmits.wordpress.com/247/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wmits.wordpress.com/247/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wmits.wordpress.com/247/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wmits.wordpress.com/247/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wmits.wordpress.com/247/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wmits.wordpress.com/247/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wmits.wordpress.com/247/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wmits.wordpress.com/247/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=247&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wmits.wordpress.com/2009/10/19/ph%e1%ba%a7n-2-function-trong-javascript/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/1fec91d3a11db1231b93d2c00d816c3e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">honpham</media:title>
		</media:content>
	</item>
		<item>
		<title>Phần 1 &#8211; Làm quen javascript</title>
		<link>http://wmits.wordpress.com/2009/10/11/ph%e1%ba%a7n-1-lam-quen-javascript/</link>
		<comments>http://wmits.wordpress.com/2009/10/11/ph%e1%ba%a7n-1-lam-quen-javascript/#comments</comments>
		<pubDate>Sun, 11 Oct 2009 14:58:49 +0000</pubDate>
		<dc:creator>honpham</dc:creator>
				<category><![CDATA[JavaScript]]></category>

		<guid isPermaLink="false">http://wmits.wordpress.com/?p=240</guid>
		<description><![CDATA[1.      Công cụ phát triển Dùng bất kỳ trình soạn thảo văn bản nào, lưu xuống định dạng file *.js cho file html Dùng Dreamweaver hỗ trợ nhắc lệnh cao. Vd: Dùng notepad viết các file sau và lưu theo *.html với *.js, chạy file html để xem kết quả. 2.      Cách chú thích Dùng [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=240&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>1.      Công cụ phát triển</p>
<p>Dùng bất kỳ trình soạn thảo văn bản nào, lưu xuống định dạng file *.js cho file html</p>
<p>Dùng Dreamweaver hỗ trợ nhắc lệnh cao.</p>
<p>Vd: Dùng notepad viết các file sau và lưu theo *.html với *.js, chạy file html để xem kết quả.</p>
<p>2.      Cách chú thích</p>
<p>Dùng // hoặc &lt;!&#8211; &#8211;&gt; để chú thích 1 dòng.</p>
<p>Dùng /* */ cho nhiều dòng.</p>
<p>3.      Khai báo đoạn script để khởi chạy JavaScript</p>
<p><span style="text-decoration:underline;">Cách 1: Chèn script</span></p>
<p>&lt;script language=&#8221;JavaScript&#8221;&gt;</p>
<p>document.write(&#8220;JavaScript&#8221;);</p>
<p>&lt;/script&gt;</p>
<p>Vào phần head hay body của file html</p>
<p>Document.write() khác document.writeln() như thế nào??? Kiểm tra thấy kết quả như nhau K</p>
<p><span style="text-decoration:underline;">Cách 2: Dùng file *.js</span></p>
<p>&lt;script language=&#8221;JavaScript&#8221; src=&#8221;function.js&#8221; /&gt;</p>
<p>File function.js chứa nội dung sau:</p>
<p><strong>function</strong> Employee(name, age, hometown) {</p>
<p>this.name = name;</p>
<p>this.age = age;</p>
<p>this.hometown = hometown;</p>
<p>}</p>
<p>var hon = new Employee(&#8220;Ngọc Hơn&#8221;, 23, &#8220;Bến Tre&#8221;);</p>
<p>document.write(hon.name + &#8221; &#8211; &#8221; + hon.hometown;</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wmits.wordpress.com/240/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wmits.wordpress.com/240/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wmits.wordpress.com/240/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wmits.wordpress.com/240/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wmits.wordpress.com/240/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wmits.wordpress.com/240/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wmits.wordpress.com/240/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wmits.wordpress.com/240/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wmits.wordpress.com/240/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wmits.wordpress.com/240/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wmits.wordpress.com/240/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wmits.wordpress.com/240/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wmits.wordpress.com/240/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wmits.wordpress.com/240/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=240&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wmits.wordpress.com/2009/10/11/ph%e1%ba%a7n-1-lam-quen-javascript/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/1fec91d3a11db1231b93d2c00d816c3e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">honpham</media:title>
		</media:content>
	</item>
		<item>
		<title>Tại sao là JavaScript</title>
		<link>http://wmits.wordpress.com/2009/10/11/t%e1%ba%a1i-sao-la-javascript/</link>
		<comments>http://wmits.wordpress.com/2009/10/11/t%e1%ba%a1i-sao-la-javascript/#comments</comments>
		<pubDate>Sun, 11 Oct 2009 14:42:05 +0000</pubDate>
		<dc:creator>honpham</dc:creator>
				<category><![CDATA[JavaScript]]></category>

		<guid isPermaLink="false">http://wmits.wordpress.com/?p=236</guid>
		<description><![CDATA[Đặt vấn đề: Trong các ứng dụng web, đối với server-side programming:  server sẽ load và kiểm tra tính hợp lệ của tất cả các giá trị input từ phía người dùng. Có lỗi sẽ gởi thông báo và yêu cầu nhập lại… Nếu như: có rất nhiều người dùng cùng truy xuất website, vấn [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=236&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Đặt vấn đề:<br />
Trong các ứng dụng web, đối với server-side programming:  server sẽ load và kiểm tra tính hợp lệ của tất cả các giá trị input từ phía người dùng. Có lỗi sẽ gởi thông báo và yêu cầu nhập lại…<br />
Nếu như: có rất nhiều người dùng cùng truy xuất website, vấn đề cải thiện tốc độ là rất quan trọng. Làm sao các giá trị input từ phía người dùng gởi lên server là các giá trị hợp lệ, để giảm bớt công việc cho server.</p>
<p>Giải quyết vấn đề:<br />
Các nhà phát triển đã đưa ra một ngôn ngữ mới, giúp kiểm tra tính hợp lệ của các giá trị ở client-side. Đó là Javascript<br />
Ngoàira, Javascript còn giúp cho trang web động hơn và có khả năng xử lý sự kiện từ phía người dùng.<br />
Javascript được tích hợp trong trình duyệt: Microsoft Internet Explorer và Netscape Nevigator.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wmits.wordpress.com/236/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wmits.wordpress.com/236/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wmits.wordpress.com/236/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wmits.wordpress.com/236/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wmits.wordpress.com/236/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wmits.wordpress.com/236/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wmits.wordpress.com/236/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wmits.wordpress.com/236/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wmits.wordpress.com/236/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wmits.wordpress.com/236/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wmits.wordpress.com/236/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wmits.wordpress.com/236/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wmits.wordpress.com/236/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wmits.wordpress.com/236/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=236&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wmits.wordpress.com/2009/10/11/t%e1%ba%a1i-sao-la-javascript/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/1fec91d3a11db1231b93d2c00d816c3e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">honpham</media:title>
		</media:content>
	</item>
		<item>
		<title>Quản Lý Thông Tin Cấu Hình Database</title>
		<link>http://wmits.wordpress.com/2009/09/17/qu%e1%ba%a3n-ly-thong-tin-c%e1%ba%a5u-hinh-database/</link>
		<comments>http://wmits.wordpress.com/2009/09/17/qu%e1%ba%a3n-ly-thong-tin-c%e1%ba%a5u-hinh-database/#comments</comments>
		<pubDate>Thu, 17 Sep 2009 14:53:51 +0000</pubDate>
		<dc:creator>queo1987</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[JSF]]></category>

		<guid isPermaLink="false">http://wmits.wordpress.com/?p=226</guid>
		<description><![CDATA[Vào Đề -       Bất cứ khi nào ứng dụng của bạn muốn giao tiếp với các dịch vụ bên ngoài, và chúng ta cần chỉ định những tham số cấu hình như: URLs, username, password,… Bạn đừng bao giờ code cứng những tham số này vào trong những class của ứng dụng, bởi vì nó [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=226&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><strong>Vào Đề</strong><br />
-       Bất cứ khi nào ứng dụng của bạn muốn giao tiếp với các dịch vụ bên ngoài, và chúng ta cần chỉ định những tham số cấu hình như: URLs, username, password,… Bạn đừng bao giờ code cứng những tham số này vào trong những class của ứng dụng, bởi vì nó sẽ tạo ra những khó khăn, rắc rối như: cập nhật lại password, thay đổi server,…<br />
-       Cụ thể hơn là database service, chúng ta sẽ quản lý thông tin cấu hình cho database. Thông thường, thông tin cấu hình được đặt trong file server.xml. Servlet container sẽ sử dụng thông tin này để tạo ra datasource và liên kết nó với một cái tên đã biết. Những class cần để truy cập database này thường sử dũng JNDI để tìm datasource.<br />
-       Chúng ta đặt thông tin cấu hình trong file server.xml thì thích hợp với những resource dùng chung như là database. Resource này, có thể được sử dụng bởi tất cả các web app bên trong container. Một cách khác, thông tin cấu hình này sẽ được đặt trong file web.xml hoặc faces-config.xml. Vì thế, chúng ta có ba khả năng sau<br />
<strong>Giải pháp</strong></p>
<h2>a)     Configuring a Bean</h2>
<p>Khi bạn định nghĩa ra một bean trong face-config.xml, bạn có thể cung cấp những tham số khởi tạo bằng cách sử dụng thẻ managed-property. Sau đây là cách khởi tạo một bean kết nối database:</p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="background:silver none repeat scroll 0 0;font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:#00b0f0;">databaseBean</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-class</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">bean.</span><span style="font-size:10pt;font-family:&quot;color:red;">DatabaseBean</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-class</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-scope</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:red;">application</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-scope</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">userRoot</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">root</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">password</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">123456</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="text-decoration:underline;"><span style="font-size:10pt;font-family:&quot;color:black;">url</span></span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">jdbc:mysql://<span style="text-decoration:underline;">localhost</span>:3306/test</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">driverClassName</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">com.mysql.jdbc.Driver</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal"><span style="font-size:10pt;line-height:115%;font-family:&quot;color:teal;">&lt;/</span><span style="background:silver none repeat scroll 0 0;font-size:10pt;line-height:115%;font-family:&quot;color:#3f7f7f;">managed-bean</span><span style="font-size:10pt;line-height:115%;font-family:&quot;color:teal;">&gt;</span></p>
<p>-       Tiếp theo, sau đây là DatabaseBean.java. Bean này cần setter cho tất cả các thuộc tính. Bởi vì khi bean được khởi tạo, những phương thức setter sẽ được gọi với những tham số đã được chỉ định trong faces-config.xml</p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">package</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> bean;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">import</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> com.mysql.jdbc.Connection;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">public</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">class</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> DatabaseBean {</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">private</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> String </span><span style="font-size:10pt;font-family:&quot;color:#0000c0;">userRoot</span><span style="font-size:10pt;font-family:&quot;color:black;">;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">private</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> String </span><span style="text-decoration:underline;"><span style="font-size:10pt;font-family:&quot;color:#0000c0;">password</span></span><span style="font-size:10pt;font-family:&quot;color:black;">;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">private</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> String </span><span style="text-decoration:underline;"><span style="font-size:10pt;font-family:&quot;color:#0000c0;">url</span></span><span style="font-size:10pt;font-family:&quot;color:black;">;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">private</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> String </span><span style="text-decoration:underline;"><span style="font-size:10pt;font-family:&quot;color:#0000c0;">driverClassName</span></span><span style="font-size:10pt;font-family:&quot;color:black;">;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">public</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">void</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> setUserRoot(String <span style="background:yellow none repeat scroll 0 0;">userRoot</span>) {</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">this</span></strong><span style="font-size:10pt;font-family:&quot;color:black;">.</span><span style="font-size:10pt;font-family:&quot;color:#0000c0;">userRoot</span><span style="font-size:10pt;font-family:&quot;color:black;"> = <span style="background:silver none repeat scroll 0 0;">userRoot</span>;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> }</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">public</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">void</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> setPassword(String password) {</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">this</span></strong><span style="font-size:10pt;font-family:&quot;color:black;">.</span><span style="font-size:10pt;font-family:&quot;color:#0000c0;">password</span><span style="font-size:10pt;font-family:&quot;color:black;"> = password;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> }</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">public</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">void</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> setUrl(String url) {</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">this</span></strong><span style="font-size:10pt;font-family:&quot;color:black;">.</span><span style="font-size:10pt;font-family:&quot;color:#0000c0;">url</span><span style="font-size:10pt;font-family:&quot;color:black;"> = url;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> }</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">public</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">void</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> setProvider(String driverClassName) {</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">this</span></strong><span style="font-size:10pt;font-family:&quot;color:black;">.</span><span style="font-size:10pt;font-family:&quot;color:#0000c0;">driverClassName</span><span style="font-size:10pt;font-family:&quot;color:black;"> = driverClassName;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> }</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">public</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> Connection getConnection(){</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:#3f7f5f;">//</span><strong><span style="font-size:10pt;font-family:&quot;color:#7f9fbf;">TODO</span></strong><span style="font-size:10pt;font-family:&quot;color:#3f7f5f;">: Connect Database and return a connection</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> Connection connect = </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">null</span></strong><span style="font-size:10pt;font-family:&quot;color:black;">;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:#3f7f5f;">//write code here to connect database</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">return</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> connect;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> }</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;">}</span></p>
<p>-       Cuối cùng, để truy xuất được đối tượng bean, ta sử dũng đoạn code sau:</p>
<p style="margin-left:0;margin-right:0;"><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">F</span></span><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">acesContext context = FacesContext.</span></span><span style="color:#000000;font-family:'Times New Roman';"><em><span style="font-size:x-small;">getCurrentInstance</span></em></span><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">();</span></span></p>
<p style="margin-left:0;margin-right:0;"><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">Application application = context.getApplication();</span></span></p>
<p style="margin-left:0;margin-right:0;"><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">ValueBinding binding =</span></span> <span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">application.</span></span><span style="background-color:#c0c0c0;color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">createValueBinding</span></span><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">(</span></span><span style="color:#2a00ff;font-family:'Times New Roman';"><span style="font-size:x-small;">&#8220;#{databaseBean}&#8221;</span></span><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">);</span></span></p>
<p style="margin-left:0;margin-right:0;"><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">DatabaseBean databaseBean = </span></span><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;"> </span></span><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">(DatabaseBean)binding.</span></span><span style="background-color:#c0c0c0;color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">getValue</span></span><span style="color:#000000;font-family:'Times New Roman';"><span style="font-size:x-small;">(context);</span></span><span style="color:#000000;"><strong><span style="font-family:'Times New Roman';"> </span></strong></span></p>
<p style="margin-left:0;margin-right:0;"><span style="color:#000000;"><strong><span style="font-family:'Times New Roman';"><span style="font-size:medium;">B. Configuring the External Context</span></span></strong></span><span style="font-family:'Times New Roman';"> </span></p>
<p style="margin-left:0;margin-right:0;"><span style="font-family:'Times New Roman';"><span style="font-size:small;">Trong phần này, chúng ta sẽ khai báo những tham số trong </span></span><span style="font-family:'Times New Roman';"><span style="font-size:small;">file web.xml</span></span><span style="font-family:'Times New Roman';"><span style="font-size:small;">. Sử dụng thẻ context-param trong web-app</span></span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">context-param</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-name</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span><span style="text-decoration:underline;"><span style="font-size:9pt;font-family:&quot;color:black;">url</span></span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-name</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-value</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:9pt;font-family:&quot;color:black;">jdbc:mysql://<span style="text-decoration:underline;">localhost</span>:3306/test</span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-value</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">context-param</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">context-param</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-name</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:9pt;font-family:&quot;color:black;">userRoot</span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-name</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-value</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:9pt;font-family:&quot;color:black;">root</span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-value</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">context-param</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">context-param</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-name</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:9pt;font-family:&quot;color:black;">password</span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-name</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-value</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:9pt;font-family:&quot;color:black;">123456</span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-value</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">context-param</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">context-param</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-name</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:9pt;font-family:&quot;color:black;">driverClassName</span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-name</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:9pt;font-family:&quot;color:black;"> </span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-value</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:9pt;font-family:&quot;color:black;">com.mysql.jdbc.Driver</span><span style="font-size:9pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;font-family:&quot;color:#3f7f7f;">param-value</span><span style="font-size:9pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal"><span style="font-size:9pt;line-height:115%;font-family:&quot;color:black;"> </span><span style="font-size:9pt;line-height:115%;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:9pt;line-height:115%;font-family:&quot;color:#3f7f7f;">context-param</span><span style="font-size:9pt;line-height:115%;font-family:&quot;color:teal;">&gt;</span></p>
<p>-       Để lấy được những giá trị tham số này, sử dụng đối tượng ExternalContext và sử dụng phương thức getInitParameter(String paramName) để lấy giá tri<br />
<!--[if gte mso 9]&gt;  Normal 0     false false false  VI ZH-TW X-NONE                            &lt;![endif]--><!--[if gte mso 9]&gt;                                                                                                                                            &lt;![endif]--> <!--[if gte mso 10]&gt;--> <!--[endif]--></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">package</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> bean;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">import</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> java.sql.Connection;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">import</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> java.sql.DriverManager;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">import</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> java.sql.SQLException;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">import</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> javax.faces.context.<span style="text-decoration:underline;">ExternalContext</span>;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">import</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> javax.faces.context.FacesContext;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">public</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">class</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> ExternalContextBean {</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;" lang="EN-US"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">public</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> Connection getConnection(){</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;" lang="EN-US"> </span><span style="font-size:10pt;font-family:&quot;color:black;">ExternalContext externalContext = FacesContext.<em>getCurrentInstance</em>().getExternalContext();</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;" lang="EN-US"> </span><span style="font-size:10pt;font-family:&quot;color:black;">String url = externalContext.getInitParameter(</span><span style="font-size:10pt;font-family:&quot;color:#2a00ff;">&#8220;url&#8221;</span><span style="font-size:10pt;font-family:&quot;color:black;">);</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;" lang="EN-US"> </span><span style="font-size:10pt;font-family:&quot;color:black;">String driverClassName = externalContext.getInitParameter(</span><span style="font-size:10pt;font-family:&quot;color:#2a00ff;">&#8220;driverClassName&#8221;</span><span style="font-size:10pt;font-family:&quot;color:black;">);</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;" lang="EN-US"> </span><span style="font-size:10pt;font-family:&quot;color:black;">String userRoot = externalContext.getInitParameter(</span><span style="font-size:10pt;font-family:&quot;color:#2a00ff;">&#8220;userRoot&#8221;</span><span style="font-size:10pt;font-family:&quot;color:black;">);</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;" lang="EN-US"> </span><span style="font-size:10pt;font-family:&quot;color:black;">String pass = externalContext.getInitParameter(</span><span style="font-size:10pt;font-family:&quot;color:#2a00ff;">&#8220;password&#8221;</span><span style="font-size:10pt;font-family:&quot;color:black;">);</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;" lang="EN-US"> </span><span style="font-size:10pt;font-family:&quot;color:black;">Connection <span style="background:yellow none repeat scroll 0 0;">connection</span> = </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">null</span></strong><span style="font-size:10pt;font-family:&quot;color:black;">;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">try</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> {</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> Class.<em>forName</em>(driverClassName);</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> <span style="background:yellow none repeat scroll 0 0;">connection</span> = DriverManager.<em>getConnection</em>(url,userRoot,pass);</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> } </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">catch</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> (ClassNotFoundException e) {</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> e.printStackTrace();</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> } </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">catch</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> (SQLException e) {</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> e.printStackTrace();</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> }</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;" lang="EN-US"> </span><strong><span style="font-size:10pt;font-family:&quot;color:#7f0055;">return</span></strong><span style="font-size:10pt;font-family:&quot;color:black;"> <span style="background:silver none repeat scroll 0 0;">connection</span>;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;">}</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;">}</span></p>
<p><strong>C. Database Driver và Thư viện</strong><br />
-       Các bước cơ bản kết nối csdl, theo thứ tự sau:</p>
<ul>
<li>Load Driver Database: Class.forname(dirverClassName)</li>
<li>Tạo Connection: Drivermanager.createConnection(url,username,password).</li>
<li>Truy xuất csdl:
<ul>
<li>Tạo Statement: Statement st = connection.createStatement()</li>
<li>Thực thi câu truy vấn, và lấy kết quả trả về là một resultSet</li>
</ul>
</li>
</ul>
<p>resultSet = Statement.excuteQuery(query) dùng cho select, insert<br />
resultSet=Statement.excuteUpdate(query) dùng cho update</p>
<ul>
<li>Xử lý dữ liệu trong result set và đóng connection
<ul>
<li>Duyệt: while(resultset.next)</li>
<li>Lấy dữ liệu: resultset.getString(columName), …(get[TypeData](columName))</li>
<li>Xử lý dữ liệu: //TODO…</li>
<li>Đóng kết nối: connection.close()</li>
</ul>
</li>
</ul>
<p>-       Tôi xin thống kê một số cơ sở dữ liệu với những thuộc tính tương ứng. Vì đôi lúc ta không thể nào nhớ driver classname, hay url connection,…</p>
<ul>
<li>MySQL</li>
</ul>
<table border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td width="172" valign="top">Connectin   Url</td>
<td width="337" valign="top">jdbc:mysql://server:port/database</td>
</tr>
<tr>
<td width="172" valign="top">Driver   Class Name</td>
<td width="337" valign="top">com.mysql.jdbc.driver</td>
</tr>
<tr>
<td width="172" valign="top">Jar file</td>
<td width="337" valign="top"><a href="http://www.mediafire.com/file/tmjzmm1en4m/mysql-connector-java-5.1.5.jar">Mysql-connector-java-5.1-bin.j</a></td>
</tr>
</tbody>
</table>
<ul>
<li>SQL Server</li>
</ul>
<table border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td width="129" valign="top">Connectin   Url</td>
<td width="253" valign="top">For SQL 2000:<br />
[jdbc:microsoft:sqlserver://server:port;databaseName=dbname]<br />
For SQL   2005 và 2008:<br />
[jdbc:sqlserver://server:port;databaseName=dbname]</td>
</tr>
<tr>
<td width="129" valign="top">Driver   Class</td>
<td width="253" valign="top">com.microsoft.sqlserver.jdbc.SQLServerDriverfds</td>
</tr>
<tr>
<td width="129" valign="top">Jar file</td>
<td width="253" valign="top"><a href="http://www.mediafire.com/file/zatymkdo3mz/sqlServer2000_driver.rar">Sqljdbc.zar</a> (for SQL Server 2000)<br />
<a href="http://www.mediafire.com/file/zatymkdo3mz/sqlServer2000_driver.rar">Sqljdbc.jar</a> (for SQL Server 2005)</td>
</tr>
</tbody>
</table>
<ul>
<li>Oracle Server</li>
</ul>
<p>Oracle có hai loại driver: JDBC Thin Driver và JDBC OCI driver.<br />
Lấy thông tin và download tại đây: <a href="http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html">JDBC Driver for Oracle</a></p>
<table style="height:66px;" border="1" cellspacing="0" cellpadding="0" width="505">
<tbody>
<tr>
<td width="129" valign="top">Connectin   Url</td>
<td width="253" valign="top">
<pre>jdbc:oracle:thin:@server:port:db-name</pre>
</td>
</tr>
<tr>
<td width="129" valign="top">Driver   Class</td>
<td width="253" valign="top">oracle.jdbc.driver.OracleDriver</td>
</tr>
<tr>
<td width="129" valign="top">Jar file</td>
<td width="253" valign="top"><a href="http://www.mediafire.com/file/mm5zjqctgiy/Oracle_jdbc_driver.jar">thin-dirver.jar</a></td>
</tr>
</tbody>
</table>
<ul>
<li>PostgressSQL</li>
</ul>
<table style="height:82px;" border="1" cellspacing="0" cellpadding="0" width="508">
<tbody>
<tr>
<td width="129" valign="top">Connectin   Url</td>
<td width="253" valign="top">
<pre>jdbc:postgresql://server/dbname</pre>
</td>
</tr>
<tr>
<td width="129" valign="top">Driver Class</td>
<td width="253" valign="top"><code>org.postgresql.Driver</code></td>
</tr>
<tr>
<td width="129" valign="top">Jar file</td>
<td width="253" valign="top"><a href="http://www.mediafire.com/file/i3gwk5lzzlz/postgresql-8.4-701.jdbc4.zip">postgresql.jar</a></td>
</tr>
</tbody>
</table>
<ol></ol>
<ul>
<li>HSQLDB</li>
</ul>
<ol></ol>
<table style="height:66px;" border="1" cellspacing="0" cellpadding="0" width="506">
<tbody>
<tr>
<td width="129" valign="top">Connectin   Ur</td>
<td width="253" valign="top">
<pre><code>jdbc:hsqldb:</code><code>data</code><code>\</code><code>dbname</code></pre>
</td>
</tr>
<tr>
<td width="129" valign="top">Driver   Class</td>
<td width="253" valign="top"><span style="font-family:Courier New;">org.hsqldb.jdbcDriver</span></td>
</tr>
<tr>
<td width="129" valign="top">Jar file</td>
<td width="253" valign="top"><a href="http://www.mediafire.com/file/gttgnnnm3im/hsqldb.jar">Hsql.jar</a></td>
</tr>
</tbody>
</table>
<div id="_mcePaste" style="overflow:hidden;position:absolute;left:-10000px;top:285px;width:1px;height:1px;">
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="background:silver none repeat scroll 0 0;font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:#00b0f0;">databaseBean</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-class</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">bean.</span><span style="font-size:10pt;font-family:&quot;color:red;">DatabaseBean</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-class</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;"> </span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-scope</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:red;">application</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-bean-scope</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">userRoot</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">root</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">password</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">123456</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="text-decoration:underline;"><span style="font-size:10pt;font-family:&quot;color:black;">url</span></span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">jdbc:mysql://<span style="text-decoration:underline;">localhost</span>:3306/test</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">driverClassName</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">property-name</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span><span style="font-size:10pt;font-family:&quot;color:black;">com.mysql.jdbc.Driver</span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">value</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal" style="margin-bottom:.0001pt;line-height:normal;"><span style="font-size:10pt;font-family:&quot;color:black;"> </span><span style="font-size:10pt;font-family:&quot;color:teal;">&lt;/</span><span style="font-size:10pt;font-family:&quot;color:#3f7f7f;">managed-property</span><span style="font-size:10pt;font-family:&quot;color:teal;">&gt;</span></p>
<p class="MsoNormal"><span style="font-size:10pt;line-height:115%;font-family:&quot;color:teal;">&lt;/</span><span style="background:silver none repeat scroll 0 0;font-size:10pt;line-height:115%;font-family:&quot;color:#3f7f7f;">managed-bean</span><span style="font-size:10pt;line-height:115%;font-family:&quot;color:teal;">&gt;</span></p>
</div>
<p>Document references: <a href="http://docs.google.com/Doc?docid=0AetTYXMiKVE6ZGczbjkyYjJfMzRnenpyNThobQ&amp;hl=en">click here to view</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wmits.wordpress.com/226/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wmits.wordpress.com/226/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wmits.wordpress.com/226/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wmits.wordpress.com/226/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wmits.wordpress.com/226/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wmits.wordpress.com/226/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wmits.wordpress.com/226/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wmits.wordpress.com/226/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wmits.wordpress.com/226/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wmits.wordpress.com/226/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wmits.wordpress.com/226/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wmits.wordpress.com/226/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wmits.wordpress.com/226/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wmits.wordpress.com/226/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=226&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wmits.wordpress.com/2009/09/17/qu%e1%ba%a3n-ly-thong-tin-c%e1%ba%a5u-hinh-database/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/81f51a7ba1cec8017cf22c5fd1fd5d61?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">queo1987</media:title>
		</media:content>
	</item>
		<item>
		<title>Excel trong java và cách hiển thị link trên Swing</title>
		<link>http://wmits.wordpress.com/2009/09/14/excel-trong-java-va-cach-hi%e1%bb%83n-th%e1%bb%8b-link-tren-swing/</link>
		<comments>http://wmits.wordpress.com/2009/09/14/excel-trong-java-va-cach-hi%e1%bb%83n-th%e1%bb%8b-link-tren-swing/#comments</comments>
		<pubDate>Mon, 14 Sep 2009 12:52:07 +0000</pubDate>
		<dc:creator>honpham</dc:creator>
				<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://wmits.wordpress.com/?p=217</guid>
		<description><![CDATA[Lấy nội dung từ file excel bằng java Dùng thư viện jxl.jar (tải file về và thêm vào build path của eclipse) Dùng 2 class sau trong file java của bạn import jxl.Sheet; import jxl.Workbook; Tạo 1 file chỉ đến file excel của bạn File file = new File(&#8220;C:\student.xls&#8221;); Đưa file này vào Workbook và [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=217&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<h3><em><span style="text-decoration:underline;">Lấy nội dung từ file excel bằng java</span></em></h3>
<ul>
<li><em>Dùng thư viện <a href="http://mirrors.ibiblio.org/pub/mirrors/maven/net.sourceforge.jexcelapi/jars/jxl-2.6.jar">jxl.jar</a> (tải file về và thêm vào build path của eclipse)</em></li>
</ul>
<ul>
<li><em>Dùng 2 class sau trong file java của bạn</em><span style="color:#800080;"><br />
</span>import jxl.Sheet;<br />
import jxl.Workbook;</li>
</ul>
<ul>
<li><em>Tạo 1 file chỉ đến file excel của bạn</em><br />
File file = new File(<span style="color:#0000ff;">&#8220;C:\student.xls&#8221;</span>);</li>
</ul>
<ul>
<li><em>Đưa file này vào Workbook và dùng vòng lặp lấy ra nội dung của từng ô trong file excel.<br />
</em> Workbook wb = Workbook.getWorkbook(file);<br />
Sheet sheet = wb.getSheet(0);<br />
int rows =<span style="color:#ff0000;"> sheet.getRows();<br />
</span><span style="color:#000000;"> </span>int cols = <span style="color:#ff0000;">sheet.getColumns();<br />
</span><span style="color:#000000;"> </span>for(int row = 0; row &lt; rows; row++) {<span style="color:#993366;"><br />
</span>for(int col = 0; col &lt; cols; col++) {<br />
System.out.println(<span style="color:#ff0000;">sheet.getCell(col, row).getContents()</span>);<br />
}<br />
}</li>
</ul>
<h3><span style="text-decoration:underline;"><em>Hiển thị link trên Swing</em></span></h3>
<ul>
<li><em>Dùng lớp Desktop của AWT và URI của NET</em><br />
import java<span style="color:#000000;">.awt.Desktop;</span><br />
import java.<span style="color:#000000;">net.URI;</span></li>
<li><em>Dùng 1 label hiển thị link</em><br />
JLabel jLabel = new JLabel(<span style="color:#0000ff;">&#8220;http://engclub.info&#8221;</span>);</li>
<li><em>Đăng ký sự kiện cho label trên</em><br />
jLabel.addMouseListener(new MouseListener() {<br />
public void <span style="color:#0000ff;">mousePressed</span>(MouseEvent e) {<br />
<span style="color:#ff0000;">Desktop desktop = Desktop.getDesktop();</span><br />
try {<br />
<span style="color:#ff0000;">desktop.browse(new URI(&#8220;http://engclub.info&#8221;));</span><br />
} catch (IOException e1) {<br />
e1.printStackTrace();<br />
} catch (URISyntaxException e1) {<br />
e1.printStackTrace();<br />
}<br />
}<br />
&#8230;&#8230;&#8230;&#8230;. // cac su kien khac<br />
}</li>
</ul>
<p><em><a href="http://www.4shared.com/file/132539481/83c1432/Excel2Ldif.html">Ví dụ tham khảo</a></em></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wmits.wordpress.com/217/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wmits.wordpress.com/217/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wmits.wordpress.com/217/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wmits.wordpress.com/217/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wmits.wordpress.com/217/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wmits.wordpress.com/217/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wmits.wordpress.com/217/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wmits.wordpress.com/217/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wmits.wordpress.com/217/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wmits.wordpress.com/217/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wmits.wordpress.com/217/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wmits.wordpress.com/217/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wmits.wordpress.com/217/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wmits.wordpress.com/217/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=217&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wmits.wordpress.com/2009/09/14/excel-trong-java-va-cach-hi%e1%bb%83n-th%e1%bb%8b-link-tren-swing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/1fec91d3a11db1231b93d2c00d816c3e?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">honpham</media:title>
		</media:content>
	</item>
		<item>
		<title>Hello world!</title>
		<link>http://wmits.wordpress.com/2009/09/10/hello-world/</link>
		<comments>http://wmits.wordpress.com/2009/09/10/hello-world/#comments</comments>
		<pubDate>Thu, 10 Sep 2009 13:59:02 +0000</pubDate>
		<dc:creator>mitadmin</dc:creator>
				<category><![CDATA[Announcement]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Hi all, Hello world is a standard beginning for most of developers And it is also a start for us :p<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=1&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Hi all,</p>
<p>Hello world is a standard beginning for most of developers <img src='http://s0.wp.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' />  And it is also a start for us :p</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wmits.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wmits.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wmits.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wmits.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wmits.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wmits.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wmits.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wmits.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wmits.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wmits.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wmits.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wmits.wordpress.com/1/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wmits.wordpress.com/1/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wmits.wordpress.com/1/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=1&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wmits.wordpress.com/2009/09/10/hello-world/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/4770487d5b01228e7d428756c7c9ac37?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">mitadmin</media:title>
		</media:content>
	</item>
		<item>
		<title>How to format Date object in Java</title>
		<link>http://wmits.wordpress.com/2009/08/25/how-to-format-date-object-in-java/</link>
		<comments>http://wmits.wordpress.com/2009/08/25/how-to-format-date-object-in-java/#comments</comments>
		<pubDate>Tue, 25 Aug 2009 08:26:26 +0000</pubDate>
		<dc:creator>phucbui</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Date]]></category>
		<category><![CDATA[SimpleDateFormat]]></category>

		<guid isPermaLink="false">http://phucbui.wordpress.com/?p=102</guid>
		<description><![CDATA[How to display an Date object like this 25-08-2009 or 2009/08/25 We can use SimpleDateFormat class to format a Date as given pattern Sample: public String getFormatedDate(Date date, String pattern){ SimpleDateFormat dateFormat = new SimpleDateFormat(pattern); String result = dateFormat.format(date); return result; } use it: getFormatedDate(new Date(), &#8220;dd-MM-yyyy&#8221;) -&#62; result is: 25-08-2009 getFormatedDate(new Date(), &#8220;yyyy/MM/dd&#8221;) -&#62; [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=102&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>How to display an Date object like this <strong>25-08-2009</strong> or <strong>2009/08/25</strong></p>
<p>We can use <span style="color:#ff6600;">SimpleDateFormat</span> class to format a Date as given pattern</p>
<p>Sample:</p>
<p>public String getFormatedDate(Date date, String pattern){<br />
SimpleDateFormat dateFormat = new SimpleDateFormat(pattern);<br />
String result = dateFormat.format(date);<br />
return result;<br />
}</p>
<p>use it:</p>
<p><span style="color:#008000;">getFormatedDate(new Date(), &#8220;dd-MM-yyyy&#8221;) </span>-&gt; result is: <span style="color:#ff0000;">25-08-2009</span></p>
<p><span style="color:#008000;">getFormatedDate(new Date(), &#8220;yyyy/MM/dd&#8221;)</span> -&gt; result is: <span style="color:#ff0000;">2009/08/25</span></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wmits.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wmits.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wmits.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wmits.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wmits.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wmits.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wmits.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wmits.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wmits.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wmits.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wmits.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wmits.wordpress.com/102/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wmits.wordpress.com/102/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wmits.wordpress.com/102/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=102&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wmits.wordpress.com/2009/08/25/how-to-format-date-object-in-java/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cb59ba47038719e879764673a6b40686?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">phucbui</media:title>
		</media:content>
	</item>
		<item>
		<title>Dom4j</title>
		<link>http://wmits.wordpress.com/2009/07/19/dom4j/</link>
		<comments>http://wmits.wordpress.com/2009/07/19/dom4j/#comments</comments>
		<pubDate>Sun, 19 Jul 2009 01:50:39 +0000</pubDate>
		<dc:creator>phucbui</dc:creator>
				<category><![CDATA[XML]]></category>
		<category><![CDATA[dom4j]]></category>
		<category><![CDATA[J2SE]]></category>

		<guid isPermaLink="false">http://phucbui.wordpress.com/?p=99</guid>
		<description><![CDATA[Hiện nay có rất nhiều thư viện hỗ trợ Java tương tác với file XML. Bài viết xin giới thiệu cách sử dụng thư viện dom4j (http://www.dom4j.org) để đọc nội dung file XML (tham khảo tại Dom4j Guide ) Tải demo tại đây Parsing XML &#8211; Trước tiên cần tạo đối tượng để quản lý [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=99&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Hiện nay có rất nhiều thư viện hỗ trợ Java tương tác với file XML.</p>
<p>Bài viết xin giới thiệu cách sử dụng thư viện <a href="http://sourceforge.net/projects/dom4j/files/" target="_blank">dom4j</a> (http://www.dom4j.org) để đọc nội dung file XML (tham khảo tại <a href="http://www.dom4j.org/dom4j-1.6.1/guide.html" target="_blank">Dom4j Guide</a> )</p>
<p>Tải demo tại <a href="http://www.4shared.com/file/119097799/a73abebe/dom4j_demo.html" target="_blank">đây</a> <img src='http://s2.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<h2>Parsing XML &#8211; Trước tiên cần tạo đối tượng để quản lý nội dung file XML.</h2>
<pre>import java.net.URL;

import org.dom4j.Document;
import org.dom4j.DocumentException;
import org.dom4j.io.SAXReader;

public class Foo {

    public Document parse(URL url) throws DocumentException {
        SAXReader reader = new SAXReader();
        Document document = reader.read(url);
        return document;
    }
}</pre>
<div><a name="Using_Iterators"></a></p>
<h2>Using Iterators &#8211; Duyệt qua file XML</h2>
<pre>    public void bar(Document document) throws DocumentException {

        Element root = document.getRootElement();

        // iterate through child elements of root
        for ( Iterator i = root.elementIterator(); i.hasNext(); ) {
            Element element = (Element) i.next();
            // do something
        }

        // iterate through child elements of root with element name "foo"
        for ( Iterator i = root.elementIterator( "foo" ); i.hasNext(); ) {
            Element foo = (Element) i.next();
            // do something
        }

        // iterate through attributes of root
        for ( Iterator i = root.attributeIterator(); i.hasNext(); ) {
            Attribute attribute = (Attribute) i.next();
            // do something
        }
     }</pre>
</div>
<div><a name="Powerful_Navigation_with_XPath"></a></p>
<h2>Powerful Navigation with XPath</h2>
<h3>Sử dụng XPath để duyệt qua nội dung file XML</h3>
<pre>    public void bar(Document document) {
        List list = document.selectNodes( "//foo/bar" );

        Node node = document.selectSingleNode( "//foo/bar/author" );

        String name = node.valueOf( "@name" );
    }</pre>
<p>For example if you wish to find all the hypertext links in an XHTML document         the following code would do the trick.</p>
<pre>    public void findLinks(Document document) throws DocumentException {

        List list = document.selectNodes( "//a/@href" );

        for (Iterator iter = list.iterator(); iter.hasNext(); ) {
            Attribute attribute = (Attribute) iter.next();
            String url = attribute.getValue();
        }
    }</pre>
<p>If you need any help learning the XPath language we highly recommend         the <a title="External Link" href="http://www.zvon.org/xxl/XPathTutorial/General/examples.html">Zvon tutorial</a> which allows you to learn by example.</div>
<div><a name="Fast_Looping"></a></p>
<h2>Fast Looping &#8211; Duyệt nội dung file XML dạng cây</h2>
<p>Ví dụ dưới đây hướng dẫn cách duyệt qua cấu trúc cây của file XML mà không phải tạo ra quá nhiều đối tượng Iterator.</p>
<pre>    public void treeWalk(Document document) {
        treeWalk( document.getRootElement() );
    }

    public void treeWalk(Element element) {
        for ( int i = 0, size = element.nodeCount(); i &lt; size; i++ ) {
            Node node = element.node(i);
            if ( node instanceof Element ) {
                treeWalk( (Element) node );
            }
            else {
                // do something....
            }
        }
    }</pre>
</div>
<div><a name="Creating_a_new_XML_document"></a></p>
<h2>Creating a new XML document &#8211; Tạo ra 1 XML Document</h2>
<pre>import org.dom4j.Document;
import org.dom4j.DocumentHelper;
import org.dom4j.Element;

public class Foo {

    public Document createDocument() {
        Document document = DocumentHelper.createDocument();
        Element root = document.addElement( "root" );

        Element author1 = root.addElement( "author" )
            .addAttribute( "name", "James" )
            .addAttribute( "location", "UK" )
            .addText( "James Strachan" );

        Element author2 = root.addElement( "author" )
            .addAttribute( "name", "Bob" )
            .addAttribute( "location", "US" )
            .addText( "Bob McWhirter" );

        return document;
    }
}</pre>
</div>
<div><a name="Writing_a_document_to_a_file"></a></p>
<h2>Writing a document to a file &#8211; Ghi đối tượng Document ra file</h2>
<p>A quick and easy way to write a Document (or any Node) to a Writer        is via the write() method.</p>
<pre>  FileWriter out = new FileWriter( "foo.xml" );
  document.write( out );</pre>
<p>If you want to be able to change the format of the output, such as pretty         printing or a compact format, or you want to be able to work with         Writer objects or OutputStream objects as the destination, then you can use the XMLWriter class.</p>
<pre>import org.dom4j.Document;
import org.dom4j.io.OutputFormat;
import org.dom4j.io.XMLWriter;

public class Foo {

    public void write(Document document) throws IOException {

        // lets write to a file
        XMLWriter writer = new XMLWriter(
            new FileWriter( "output.xml" )
        );
        writer.write( document );
        writer.close();

        // Pretty print the document to System.out
        OutputFormat format = OutputFormat.createPrettyPrint();
        writer = new XMLWriter( System.out, format );
        writer.write( document );

        // Compact format to System.out
        format = OutputFormat.createCompactFormat();
        writer = new XMLWriter( System.out, format );
        writer.write( document );
    }
}</pre>
</div>
<div><a name="Converting_to_and_from_Strings"></a></p>
<h2>Converting to and from Strings</h2>
<p>If you have a reference to a Document or any other Node such as an          Attribute or Element, you can turn it into the default XML text         via the asXML() method.</p>
<pre>        Document document = ...;
        String text = document.asXML();</pre>
<p>If you have some XML as a String you can parse it         back into a Document again using the helper method          DocumentHelper.parseText()</p>
<pre>        String text = "&lt;person&gt; &lt;name&gt;James&lt;/name&gt; &lt;/person&gt;";
        Document document = DocumentHelper.parseText(text);</pre>
</div>
<div><a name="Styling_a_Document_with_XSLT"></a></p>
<h2>Styling a Document with XSLT &#8211; Sử dụng XSLT</h2>
<p>Applying XSLT on a Document is quite straightforward using the          <a title="External Link" href="http://java.sun.com/xml/">JAXP</a> API from Sun.          This allows you to work against any XSLT engine such as Xalan or SAXON.         Here is an example of using JAXP to create a transformer and then          applying it to a Document.</p>
<pre>import javax.xml.transform.Transformer;
import javax.xml.transform.TransformerFactory;

import org.dom4j.Document;
import org.dom4j.io.DocumentResult;
import org.dom4j.io.DocumentSource;

public class Foo {

    public Document styleDocument(
        Document document,
        String stylesheet
    ) throws Exception {

        // load the transformer using JAXP
        TransformerFactory factory = TransformerFactory.newInstance();
        Transformer transformer = factory.newTransformer(
            new StreamSource( stylesheet )
        );

        // now lets style the given document
        DocumentSource source = new DocumentSource( document );
        DocumentResult result = new DocumentResult();
        transformer.transform( source, result );

        // return the transformed document
        Document transformedDoc = result.getDocument();
        return transformedDoc;
    }
}</pre>
</div>
<div>
<hr /></div>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wmits.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wmits.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wmits.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wmits.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wmits.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wmits.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wmits.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wmits.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wmits.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wmits.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wmits.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wmits.wordpress.com/99/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wmits.wordpress.com/99/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wmits.wordpress.com/99/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=99&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wmits.wordpress.com/2009/07/19/dom4j/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cb59ba47038719e879764673a6b40686?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">phucbui</media:title>
		</media:content>
	</item>
		<item>
		<title>JSF &#8211; Hiển thị bảng</title>
		<link>http://wmits.wordpress.com/2009/07/07/jsf-hi%e1%bb%83n-th%e1%bb%8b-b%e1%ba%a3ng/</link>
		<comments>http://wmits.wordpress.com/2009/07/07/jsf-hi%e1%bb%83n-th%e1%bb%8b-b%e1%ba%a3ng/#comments</comments>
		<pubDate>Tue, 07 Jul 2009 06:22:16 +0000</pubDate>
		<dc:creator>phucbui</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[JSF]]></category>
		<category><![CDATA[list]]></category>

		<guid isPermaLink="false">http://phucbui.wordpress.com/?p=95</guid>
		<description><![CDATA[&#60;h:dataTable value=&#8221;#{users}&#8221; var=&#8221;user&#8221; border=&#8221;1&#8243;&#62; &#60;h:column&#62; &#60;f:facet name=&#8221;header&#8221;&#62; &#60;!&#8211; tiêu đề cột&#8211;&#62; &#60;h:outputText value=&#8221;ID&#8221; /&#62; &#60;/f:facet&#62; &#60;h:outputText value=&#8221;#{user.id}&#8221; /&#62; &#60;!&#8211; giá trị của cột&#8211;&#62; &#60;/h:column&#62; &#60;h:column&#62; &#60;f:facet name=&#8221;header&#8221;&#62; &#60;h:outputText value=&#8221;First Name&#8221; /&#62; &#60;/f:facet&#62; &#60;h:outputText value=&#8221;#{user.fname}&#8221; /&#62; &#60;/h:column&#62; &#60;/h:dataTable&#62; Ghi chú: users: là 1 đối tượng Collection (List, Set) user: là 1 biến tạm, đại diện 1 [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=95&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>&lt;h:dataTable value=&#8221;#{<span style="color:#ff0000;">users</span>}&#8221; var=&#8221;<span style="color:#99cc00;">user</span>&#8221; border=&#8221;1&#8243;&gt;<br />
&lt;h:column&gt;<br />
&lt;f:facet name=&#8221;header&#8221;&gt; &lt;!&#8211; tiêu đề cột&#8211;&gt;<br />
&lt;h:outputText value=&#8221;<span style="color:#33cccc;">ID</span>&#8221; /&gt;<br />
&lt;/f:facet&gt;<br />
&lt;h:outputText value=&#8221;#{user.id}&#8221; /&gt; &lt;!&#8211; giá trị của cột&#8211;&gt;<br />
&lt;/h:column&gt;<br />
&lt;h:column&gt;<br />
&lt;f:facet name=&#8221;header&#8221;&gt;<br />
&lt;h:outputText value=&#8221;<span style="color:#33cccc;">First Name</span>&#8221; /&gt;<br />
&lt;/f:facet&gt;<br />
&lt;h:outputText value=&#8221;#{user.fname}&#8221; /&gt;<br />
&lt;/h:column&gt;<br />
&lt;/h:dataTable&gt;</p>
<p>Ghi chú:</p>
<p><span style="color:#ff0000;">users</span>: là 1 đối tượng Collection (List, Set)</p>
<p><span style="color:#99cc00;">user</span>: là 1 biến tạm, đại diện 1 đối tượng trong tập hợp users</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wmits.wordpress.com/95/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wmits.wordpress.com/95/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wmits.wordpress.com/95/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wmits.wordpress.com/95/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wmits.wordpress.com/95/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wmits.wordpress.com/95/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wmits.wordpress.com/95/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wmits.wordpress.com/95/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wmits.wordpress.com/95/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wmits.wordpress.com/95/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wmits.wordpress.com/95/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wmits.wordpress.com/95/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wmits.wordpress.com/95/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wmits.wordpress.com/95/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=95&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wmits.wordpress.com/2009/07/07/jsf-hi%e1%bb%83n-th%e1%bb%8b-b%e1%ba%a3ng/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cb59ba47038719e879764673a6b40686?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">phucbui</media:title>
		</media:content>
	</item>
		<item>
		<title>Sử dụng RSS</title>
		<link>http://wmits.wordpress.com/2009/06/18/s%e1%bb%ad-d%e1%bb%a5ng-rss/</link>
		<comments>http://wmits.wordpress.com/2009/06/18/s%e1%bb%ad-d%e1%bb%a5ng-rss/#comments</comments>
		<pubDate>Thu, 18 Jun 2009 07:17:06 +0000</pubDate>
		<dc:creator>phucbui</dc:creator>
				<category><![CDATA[Office]]></category>
		<category><![CDATA[outlook]]></category>
		<category><![CDATA[rss]]></category>

		<guid isPermaLink="false">http://phucbui.wordpress.com/?p=92</guid>
		<description><![CDATA[RSS là gì? RSS (Really Simple Syndication) là định dạng dữ liệu dựa theo chuẩn XML được sử dụng để chia sẻ và phát tán nội dung Web. Việc sử dụng các chương trình đọc tin (News Reader, RSS Reader hay RSS Feeds) sẽ giúp bạn luôn xem được nhanh chóng tin tức mới nhất [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=92&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>RSS là gì?</p>
<p>RSS (Really Simple Syndication) là định dạng dữ liệu dựa theo chuẩn XML được sử dụng để chia sẻ và phát tán nội dung Web. Việc sử dụng các chương trình đọc tin (News Reader, RSS Reader hay RSS Feeds) sẽ giúp bạn luôn xem được nhanh chóng tin tức mới nhất từ MobileNet. Mỗi tin dưới dạng RSS sẽ gồm : Tiêu đề, tóm tắt nội dung và đường dẫn nối đến trang Web chứa nội dung đầy đủ của tin.</p>
<p style="font-family:arial;">Chương trình đọc RSS là gì?</p>
<p style="font-family:arial;">RSS Reader là phần mềm có chức năng tự động lấy tin tức đã được cấu trúc theo định dạng RSS. Một số phần mềm đọc RSS cho phép bạn lập lịch cập nhật tin tức. Với chương trình đọc RSS, bạn có thể nhấn chuột vào tiêu đề của 1 tin để đọc phần tóm tắt của hoặc mở ra nội dung của toàn bộ tin trong một cửa sổ trình duyệt mặc định. Có rất nhiều phần mềm phục vụ khai thác tin qua định dạng RSS, bạn có thể tham khảo bảng các chương trình đọc RSS bên cạnh và lựa chọn cái bạn thích nhất.</p>
<p><span style="font-family:arial;">(Theo echip.com.vn)</span><br />
<span style="font-family:arial;">&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;</span></p>
<p style="font-family:arial;"><span style="font-size:130%;">Outlook và RSS </span></p>
<p style="font-family:arial;">Ở đây mình sử dụng MS Outlook 2K7</p>
<p style="font-family:arial;">Tool &gt; Account Settings &gt; Chọn tab RSS Feed &gt; Chọn New… &gt; Nhập vào link RSS &gt; Chọn các tùy chọn mặc định &gt; OK</p>
<p style="font-family:arial;">Khi check tin RSS thì vào thư mục RSS Feeds trên cây thư mục.</p>
<p style="font-family:arial;"><span style="font-size:130%;">Link RSS </span></p>
<p style="font-family:arial;">Link của 1 file tin RSS ko phải là 1 link như bình thường, và ko phải trang web nào cũng có.</p>
<p style="font-family:arial;">Chỉ những trang có ký hiệu như vậy <a href="http://tbn1.google.com/images?q=tbn:NeLNh5pVVgo1OM:http://www.gustavus.edu/xml/rssicon.png"><img style="cursor:pointer;width:20px;height:20px;" src="http://tbn1.google.com/images?q=tbn:NeLNh5pVVgo1OM:http://www.gustavus.edu/xml/rssicon.png" border="0" alt="" /></a> <span style="font-family:arial;">hoặc chữ RSS. Bấm vào đó bạn sẽ đc cung cấp link của các trang tin RSS, lấy link đó paste vào RSS Feeds của Outlook là xong.</span></p>
<p><span style="font-family:arial;font-size:130%;">Subcribe Feed</span><span style="font-family:arial;"> &#8211; 1 cách khác để đưa link RSS vào Outlook</span><br />
<span style="font-family:arial;">Thông thường khi click vào biểu tượng RSS, nó sẽ đưa qua trang RSS, và trên đó sẽ có phần &#8220;Subcribe this feed using &#8220;, bạn chọn Outlook rồi OK -&gt; như vầy đơn giản hơn <img src='http://s0.wp.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </span></p>
<p>Cheers,<br />
Phuc Bui</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wmits.wordpress.com/92/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wmits.wordpress.com/92/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wmits.wordpress.com/92/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wmits.wordpress.com/92/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wmits.wordpress.com/92/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wmits.wordpress.com/92/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wmits.wordpress.com/92/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wmits.wordpress.com/92/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wmits.wordpress.com/92/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wmits.wordpress.com/92/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wmits.wordpress.com/92/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wmits.wordpress.com/92/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wmits.wordpress.com/92/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wmits.wordpress.com/92/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wmits.wordpress.com&amp;blog=9418532&amp;post=92&amp;subd=wmits&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wmits.wordpress.com/2009/06/18/s%e1%bb%ad-d%e1%bb%a5ng-rss/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/cb59ba47038719e879764673a6b40686?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">phucbui</media:title>
		</media:content>

		<media:content url="http://tbn1.google.com/images?q=tbn:NeLNh5pVVgo1OM:http://www.gustavus.edu/xml/rssicon.png" medium="image" />
	</item>
	</channel>
</rss>
