| preg_split() | ใช้แยกค่าของ text แล้วเก็บไว้ที่ array |
|---|
function:preg_split ( pattern, text, limit )
return type:array
content:ใช้แยกค่าของ text แล้วเก็บไว้ที่ array โดยตัวแบ่งที่ใช้แยก ให้กำหนดเป็น pattern ที่ต้องการ ( ประมวลผลเร็วกว่าฟังก์ชัน split() )
example:$text = "web site bam boo lab code dot com"; $arr = preg_split ( " ", $text );