<?php
$a = array(
array(
'|174|September|2001|',
'|Pengantar=Hello!!!!',
'|Tema= Sami Mawon',
'|Tema_isi=meet you!!!',
'|Kutip=people',
'|Kutip_kitab=Efesus',
'|Kutip_pasal=4',
'|Kutip_ayat=28',
'|Tema_sumber=Kiriman dari Maurits albert (romind@ )',
'[[Kategori:e-humor 2001]]',
)
);
$pattern = '/(?<first>\w+)[:=](?<rest>[\d|\w|\s]+)/';
$matches = array();
foreach ($a as $_arrEach) {
foreach ($_arrEach as $_each) {
$result = preg_match($pattern, $_each, $matches[]);
}
}
echo "<pre>";
print_r($matches);
echo "</pre>";
preferences:
41.9 ms | 402 KiB | 5 Q