2 $HAANGA_VERSION = '1.0.3';
3 /* Generated from /home/crodas/projects/playground/haanga/tests/assert_templates/ifchanged.tpl */
4 function haanga_be17029b5fd2998df7c922a92652b6886d7780fd($vars, $return=FALSE, $blocks=array())
6 global $test_global, $global1;
11 $sorted_users = $users;
13 foreach ($sorted_users as $key => $item) {
14 $field[$key] = $item[$regroup_field];
16 array_multisort($field, SORT_REGULAR
, $sorted_users);
19 foreach ($sorted_users as $user) {
22 $buffer1 = 'Users with '.htmlspecialchars($user['age']).' years';
23 if (isset($ifchanged1) == FALSE ||
$ifchanged1 != $buffer1) {
25 $ifchanged1 = $buffer1;
28 '.htmlspecialchars($user['name']).'
34 foreach ($sorted_users as $user) {
37 if ((isset($ifchanged2[0]) == FALSE ||
$ifchanged2[0] != $user['age']) && (isset($ifchanged2[1]) == FALSE ||
$ifchanged2[1] != $user['foo'])) {
38 echo 'Users with '.htmlspecialchars($user['age']).' years';
39 $ifchanged2 = Array($user['age'], $user['foo']);
44 '.htmlspecialchars($user['name']).'
49 if ($return == TRUE) {
50 return ob_get_clean();