added function to search paragraphs for term