I'm trying to fetch my articles and I need to make a slider out of them.
Each of my articles has an image inside it's text, like this:
<p>
<img src="story_img.jpg" width=120 height=80>
In the last couple of weeks I often had to download a lot of files, submitted to a web-based teaching platform. Downloading all these files by hand is very annoying so I implemented a short Groovy script. Since Groovy has a great support for parsing well-formed XML-like information it fails if you want to parse unstructured and nasty HTML code.
</p>
Now what I need is simple, first I should parse the image and then remove it from the text .
So that I could have 2 constants
$imgOfText = ?
$TextWithOutImg = ?
I tried different ways in php and even read this topic.
But I couldn't do that.