an algorithm to extract content from a html page