class WeixinSyncer
Public Instance Methods
_handle_node(node)
click to toggle source
# File lib/syncers/weixin_syncer.rb, line 10 def _handle_node(node) node.children.each do |child_node| case child_node.name when 'img' child_node['src'] = child_node['data-src'] child_node['data-src'] = nil end end node.to_html end
get_article_xpath()
click to toggle source
# File lib/syncers/weixin_syncer.rb, line 6 def get_article_xpath '//div[contains(@class, "rich_media_content") and contains(@id, "js_content")]' end