I want to get multi result from Regex, but its not correctly work.
Test string:
<div class="row-fluid pybar-row">
<span class="pybar-label text-left">
<span class="">Male</span>
</span>
<span class="pybar-bars">
<div class="row-fluid">
<span class="pybar-bar pybar-l" style="">
<span class="pybar-bg">
<span style="width:100%"> </span>
</span>
</span>
<span class="pybar-bar pybar-r">
<span class="pybar-bg">
<span style="width:78%;"> </span>
</span>
</span>
</div>
</div>
I want to get only number of style="width:X%"
I used this regex:
$re = "/<span class=\"pybar-bg\">.*?width:(.*?)%/s";
But its only return first number. I want all numbers in string and have this class.