开发者

Scrubyt: Using big5 strings in query_field for fill_textfield

Does anyo开发者_如何学Gone know of a way to get fill_textfield to accept a big5-encoded string in the query_field? I keep getting an "unterminated string meets end of file" error with this:

require 'rubygems'
require 'scrubyt'
search_data = Scrubyt::Extractor.define do
    fetch 'http://www.google.com/ncr'
  fill_textfield 'q', '你好世界'
  submit
end


Solved: The 2-byte big5 character was messing with the " ' " closing the string. Add a space after the Chinese and it works.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜