Code Duplication    Length = 5-6 lines in 2 locations

main/survey/survey.lib.php 2 locations

@@ 2809-2813 (lines=5) @@
2806
                } else {
2807
                    foreach ($possible_option as $option_id => & $value) {
2808
                        if ($questions[$question_id]['type'] == 'percentage') {
2809
                            if (!empty($answers_of_user[$question_id][$option_id])) {
2810
                                echo "<td align='center'>";
2811
                                echo $answers_of_user[$question_id][$option_id]['value'];
2812
                                echo "</td>";
2813
                            }
2814
                        }
2815
                        else {
2816
                            echo '<td align="center">';
@@ 2818-2823 (lines=6) @@
2815
                        else {
2816
                            echo '<td align="center">';
2817
                            if (!empty($answers_of_user[$question_id][$option_id])) {
2818
                                if ($answers_of_user[$question_id][$option_id]['value'] != 0) {
2819
                                    echo $answers_of_user[$question_id][$option_id]['value'];
2820
                                }
2821
                                else {
2822
                                    echo 'v';
2823
                                }
2824
                            }
2825
                        } // </hub>
2826
                    }