I have an HTML page in an iframe that is provided by a user. I want to have a list of all urls referenced in this HTML page anywhere. This includes links in CSS files and in style attributes.
For example, running it on this code:
<div>
<style>
ul {
background: url("exampleImage.png") #00D no-repeat fixed;
}
</style>
<ul style="list-style: square url(http://www.example.com/redball.png);">
<li><a href="http://www.example.com/foobar">test</a></li>
</ul>
</div>
should return these urls:
exampleImage.png
http://www.example.com/redball.png
http://www.example.com/foobar