My image class
$temp=<img class="alignnone wp-image-6" alt="2166105529_70dd50ef4b_n" src="http://192.168.1.12/wordpress/wp-content/uploads/2013/03/2166105529_70dd50ef4b_n-300x175.jpg" width="180" height="105">
I want to grab width and height from the url i.e. width="180"
and height="105"
I had already got the src part of that using
preg_replace('/<img\s.*?\bsrc="(.*?)".*?>/si', $temp, $matches);
$matches= it contains extracted src like this
http://192.168.1.12/wordpress/wp-content/uploads/2013/03/2166105529_70dd50ef4b_n-300x175.jpg
Now how to extract width and height using regex or any other method also accepted??