Home › PHP
ereg('pattern', $string, $matches)
เป็น
preg_match('/pattern/', $string, $matches)
eregi('pattern', $string, $matches)
เป็น
preg_match('/pattern/i', $string, $matches)
เปลี่ยน
ereg_replace('pattern', $string, $matches)
เป็น
preg_replace('/pattern/', $string, $matches)
eregi_replace('pattern', $string, $matches)
เป็น
preg_replace('/pattern/i', $string, $matches)