fork download
  1. <?php
  2. $str = <<< EOF
  3. *override*
  4. I've been stuck in a room lately, and though it's hard to stay creative all the time, sometimes you need that extra kick. Well for some us we have to throw pictures of true creative genius at ourselves to stimulate us.
  5. So sit back and soak in some inspiration I've come across the past year.
  6. &nbsp;
  7. &nbsp;
  8. &nbsp;
  9. <figure>
  10.   <a href="">
  11.   <img class="aligncenter" src="http://f...content-available-to-author-only...t.com/wp-content/uploads/2011/07/Talesandminimalism_12_www.funnypagenet.com_.jpg" alt="" width="574" height="838" />
  12.   </a>
  13.   <figcaption></figcaption>
  14. </figure>
  15. &nbsp;
  16. &nbsp;
  17. &nbsp;
  18. &nbsp;
  19. <h4 style="text-align: center;">
  20.   <a href="http://f...content-available-to-author-only...t.com/tales-and-minimalism/">source</a>
  21. </h4>
  22. Couldn't find who did this, but couldn't explain the movie any simpler
  23. &nbsp;
  24. &nbsp;
  25. &nbsp;
  26. &nbsp;
  27. &nbsp;
  28. &nbsp;
  29. &nbsp;
  30. &nbsp;
  31. &nbsp;
  32. <figure>
  33.   <img class="aligncenter" src="http://b...content-available-to-author-only...s.com/2011/05/theempirestrikesback1.jpg" alt="" width="540" height="800" />
  34.   <figcaption></figcaption>
  35. </figure>
  36. &nbsp;
  37. &nbsp;
  38. &nbsp;
  39. EOF;
  40. if ( preg_match_all('~^(.*?<img\s.*?<img\s[^>]*>)~si', $str, $m) )
  41. print_r ( $m[1] );
  42. ?>
Success #stdin #stdout 0.02s 13112KB
stdin
Standard input is empty
stdout
Array
(
    [0] => *override*
I've been stuck in a room lately, and though it's hard to stay creative all the time,         sometimes you need that extra kick. Well for some us we have to throw pictures of true creative genius at ourselves to stimulate us.
So sit back and soak in some inspiration I've come across the past year.
&nbsp;
&nbsp;
&nbsp;
<figure>
    <a href="">
    <img class="aligncenter" src="http://f...content-available-to-author-only...t.com/wp-content/uploads/2011/07/Talesandminimalism_12_www.funnypagenet.com_.jpg" alt="" width="574" height="838" />
    </a>
    <figcaption></figcaption>
</figure>
&nbsp;
&nbsp;
&nbsp;
&nbsp;
<h4 style="text-align: center;">
    <a href="http://f...content-available-to-author-only...t.com/tales-and-minimalism/">source</a>
</h4>
Couldn't find who did this, but couldn't explain the movie any simpler
&nbsp;
&nbsp;
&nbsp;
&nbsp;
&nbsp;
&nbsp;
&nbsp;
&nbsp;
&nbsp;
<figure>
    <img class="aligncenter" src="http://b...content-available-to-author-only...s.com/2011/05/theempirestrikesback1.jpg" alt="" width="540" height="800" />
)