Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save sampsonbryce/f6e2a8ba2836ac58e4aa9b0ff3d83d68 to your computer and use it in GitHub Desktop.
Save sampsonbryce/f6e2a8ba2836ac58e4aa9b0ff3d83d68 to your computer and use it in GitHub Desktop.
Function to scrape html of content from page to make searchable pdfs
function getHtml(){ var w = window.open(); $(w.document.body).append('<input type="textarea" />').text($('section[role="main"]').find('iframe').contents().find('html').html());
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment