Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // grouping array data with same value
- // this is sample data
- $data = array('1','4','7','4','3','5','1','4');
- //process for grouping data with same value
- foreach($data as $rows=>$val){
- @$hasil[$val][] = $val;
- }
- //output
- print_r($hasil);
- //follow me : @ericariyanto
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement