i have this variable $img = $_POST['cur_image'];
where the content of cur_image and so $img is:
<img style="display: inline;" src="http://news.bbcimg.co.uk/media/images/65348000/jpg/_65348094_belreuters.jpg" id="1" width="100"><img style="display: none;" src="http://news.bbcimg.co.uk/media/images/65356000/jpg/_65356067_65356066.jpg" id="2" width="100"><img style="display: none;" src="http://news.bbcimg.co.uk/media/images/65367000/jpg/_65367308_coffee.jpg" id="3" width="100"><img style="display: none;" src="http://news.bbcimg.co.uk/media/images/65376000/jpg/_65376729_heart.jpg" id="4" width="100">
So i need to extract only link of the first image that i got i.e. (http://news.bbcimg.co.uk/media/images/65348000/jpg/_65348094_belreuters.jpg)
and than send to db such as
mysql_query("INSERT INTO `table` (img) VALUES ('$img')");