/home/pt/jiexi  content is:
<ul id="ul_list">
<li class="expli"><a href="tv_play-hdteleplay_20100211_7168444.html"
title="ok1"></a></li>
<li><a href="tv_play-hdteleplay_20100211_7168445.html"
title="ok2"></a></li>
<li><a href="tv_play-hdteleplay_20100211_7168446.html"
title="ok3"></a></li>
<li><a href="tv_play-hdteleplay_20100211_7168447.html"
title="ok4"></a></li>
</ul>

require 'rubygems'
require 'nokogiri'
doc = Nokogiri::HTML.parse(open('/home/pt/jiexi'))
table=doc.xpath('//ul[@id="ul_list"]/li/a')
puts table
output
irb(main):005:0> puts table
<a href="tv_play-hdteleplay_20100211_7168444.html" title="ok1"></a>
<a href="tv_play-hdteleplay_20100211_7168445.html" title="ok2"></a>
<a href="tv_play-hdteleplay_20100211_7168446.html" title="ok3"></a>
<a href="tv_play-hdteleplay_20100211_7168447.html" title="ok4"></a>
=> nil
puts table.xpath('//ul')
irb(main):006:0> puts table.xpath('//ul')
<ul id="ul_list">
<li class="expli"><a href="tv_play-hdteleplay_20100211_7168444.html"
title="ok1"></a></li>
<li><a href="tv_play-hdteleplay_20100211_7168445.html"
title="ok2"></a></li>
<li><a href="tv_play-hdteleplay_20100211_7168446.html"
title="ok3"></a></li>
<li><a href="tv_play-hdteleplay_20100211_7168447.html"
title="ok4"></a></li>
</ul>

what i think is the  script "puts table.xpath('//ul')" will not create
any output.
how strange it is to  get the result,would  you mind to  tell me  why?
-- 
Posted via http://www.ruby-forum.com/.