hpple icon indicating copy to clipboard operation
hpple copied to clipboard

Get element's innerHtml without element's tags?

Open matt-curtis opened this issue 12 years ago • 2 comments

How can I get the raw HTML of an element, not include the tags of that element? For example, if i were getting

, and body looks like this: stuff in body

How can I get only:

stuff in body

Currently the raw property includes the tags of the target element itself.

matt-curtis avatar May 18 '13 23:05 matt-curtis

Your question doesn't seem to make sense? Can you post the HTML code you are looking at? I may be able to help you.

ghost avatar Jun 28 '13 20:06 ghost

It's been awhile so I've moved to another solution, but when using Hpple if I wanted the innerHTML of body, I'd get "[body]all of body's content here[/body]" not just "all of body's content here", which is what innerHTML is technically supposed to give.

In my original question the tags where stripped out, leading to your confusion.

matt-curtis avatar Jun 28 '13 20:06 matt-curtis