21,886
社区成员
发帖
与我相关
我的任务
分享
<?
$str='<object class="OBJECT" id="MediaPlayer" classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95" width="480" height="360" align="middle">
<param name="AUTOSTART" value="false" />
<param name="ShowStatusBar" value="-1" />
<param name="Filename" value="/d/file/shipindianbo/2009-10-15/64a2790d9392db0fe4fc24206af3205b.wmv" /> <embed width="480" height="360" type="application/x-oleobject codebase=http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701" src="/d/file/shipindianbo/2009-10-15/64a2790d9392db0fe4fc24206af3205b.wmv" flename="mp"> </embed> </object>';
$str=preg_replace('(width=\"\d+\")','width="260"',$str);
$str=preg_replace('(height=\"\d+\")','height="216"',$str);
?>
<?=$str?>
$str='<object class="OBJECT" id="MediaPlayer" classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95" width="480" height="360" align="middle">
<param name="AUTOSTART" value="false" />
<param name="ShowStatusBar" value="-1" />
<param name="Filename" value="/d/file/shipindianbo/2009-10-15/64a2790d9392db0fe4fc24206af3205b.wmv" /> <embed width="480" height="360" type="application/x-oleobject codebase=http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701" src="/d/file/shipindianbo/2009-10-15/64a2790d9392db0fe4fc24206af3205b.wmv" flename="mp"> </embed> </object>';
$str=preg_replace('(width=\"\d+\")','width="200"',$str);
echo htmlspecialchars($str);
<?
$str=preg_replace('(width=\"\d+\")','width="260"',$bqr[newstext]);
$str=preg_replace('(height=\"\d+\")','height="216"',$str);
?>
<?=$str?>
$str=' <align="middle" height="360" width="480">';
$str=preg_replace('(width=\"\d+\")','width="260"',$str);
echo htmlspecialchars($str);
$str='wqdqw qdqwdqd width="325325" qwdqwdqwdqw';
$str=preg_replace('(width=\"\d+\")','width="260"',$str);
echo $str;
$str='width="325325"';
preg_replace("(\d+)", "216", $str);