Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Thanks. I wish there was a way to remove the comments and just straight read the story


On http://www.flownet.com/ron/xooglers.html, from the console

  var jq = document.createElement('script');
  jq.src = "http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js";
  document.getElementsByTagName('head')[0].appendChild(jq);

  fromP = jQuery('span').filter(function() {
      return jQuery(this).text().match(/said\.\.\./);
  }).closest("p");
  commentP = fromP.next("p");
  timeP = commentP.next("p");

  fromP.remove();
  commentP.remove();
  timeP.remove();
I haven't QA'ed this beyond a quick eyeball of the results. Obviously it could delete a lot of stuff unintentionally if comments further down the page are of a different format, but the html converted word doc doesn't give you a whole lot to work with.


Try searching for the string "posted by"




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: