I am grabbing URLs from the database. Then with each URL, I need to open that file, and only display the contents between <h1> tags and discard the rest.
-- IMPORTANT --
I do not want to actually remove everything else from each file, I simply want to echo out the contents of whatever is contained inside the <h1> tags.
I have tried str_replace, as well as preg_replace, and I cannot seem to get it right! Any pointers on how to accomplish this? Thank you!!