How do I find text between two strings?
Category: commons.lang, viewed: 8417 time(s).
In this example we'll use the StringUtils.substringBetween() method. Here we'll extract the title and body of our HTML document. Let's see the code.
By print out the title and content we'll see something similar to:
title = Hello World from Java content = Hello, today is: Tue Apr 08 07:02:39 ICT 2008
Download Hundreds of Complimentary Industry Resources
Get hundreds of popular Industry magazines, white papers, webinars, podcasts, and more;
all available at no cost to you. With more than 600 complimentary offers, you'll find
plenty of titles to suit your professional interests and needs.
Click Here and Sign up today!


