Sorun preg_replace() ile çözüldü. Diğer kod kirliliğine gerek yokmuş![]()
Aşağıdaki örnekte sadece en son veri siliniyor. preg_match ile bulunan tüm verileri silmek için nasıl bir ekleme yapmam gerekiyor ?
PHP Kodu:<?
$text = "test1 ab ss ac test2 ab bb ac test3";
preg_match_all("#ab(.*?)ac#si",$text,$cikti);
$say = count($cikti[0]);
echo $say . "\n";
for($x=0;$x<$say;$x++) {
$sil = $cikti[0][$x];
$a = Array($sil);
$a1 = Array("");
$a2 = str_replace($a,$a1,$text);
}
echo $a2;
?>
Server Yönetimi + Güvenlik --> TcpSecurity.com
Sorun preg_replace() ile çözüldü. Diğer kod kirliliğine gerek yokmuş![]()
Server Yönetimi + Güvenlik --> TcpSecurity.com
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks