- الرئيسية
- ما الجديد !
-
الصفحات▼
الصفحات
$images = array();
$pbb[text] = stripslashes($pbb[text]);
preg_match_all('/src=([\'"])?((?(1).*?|\S+))(?(1)\1)/', $pbb[text], $images);
foreach ($images[2] as $src)
{
if($src)
{
echo '<img border="0" width="200" height="200" src="'.$src.'" alt="'.$pbb['title'].'">';
}
break;
}
if(!preg_match_all('/src=([\'"])?((?(1).*?|\S+))(?(1)\1)/', $pbb[text], $images))
{
echo '<img border="0" width="200" height="200" src="http://www.nmor.net/nn/look/portal/images/traffic_cone.png" alt="'.$pbb['title'].'">';
}