ttrss_plugin-af_feedmod icon indicating copy to clipboard operation
ttrss_plugin-af_feedmod copied to clipboard

Select /html/body/

Open lbell opened this issue 11 years ago • 5 comments

Any way to select an entire body of a page? I'm working on one that has no div or classes or much of anything except text wrapped in a body tag.

lbell avatar Feb 24 '14 23:02 lbell

I'm in the same boat... I want to pull a comic image from a page that has no classes. This doesn't seem to work (Firebug says it's the xpath to the image tag).

"xpath": "html/body/table/tbody/tr[2]/td/table/tbody/tr/td[2]/table/tbody/tr/td/table/tbody/tr[2]/td/img"

ravenx99 avatar Jun 12 '14 14:06 ravenx99

Can you provide a sample url?

m42e avatar Jul 25 '14 03:07 m42e

I'm having a similar issue with a page without usable DIV classes. I have found a unique locator but can't seem to get it to pull body text.

Here is an example page: http://paddocktalk.com/news/html/story-259326.html Here is the unique string: "IMG SRC=http://paddocktalk.com/news/html/images/smilies/icon_smile.gif" I've tried all variations of XPATH that I can think of. My other pages with div classes are working perfectly.

troydunham avatar Aug 11 '14 17:08 troydunham

It seems to me, that it is not a proper xml format, maybe some tags are missing or there is no encoding specified so some characters can not be read successfully. This will lead to errors and the xpath selection is not performed. You can try my version and use the split method. https://github.com/m42e/ttrss_plugin-af_feedmod

m42e avatar Aug 11 '14 18:08 m42e

Ok, i digged in deeper.

@troydunham try: "xpath" : "td[@width='85%' and @valign='top' and @bgcolor='#FFFFFF']" and you may be near the treasure.....

m42e avatar Aug 11 '14 21:08 m42e