Code Duplication    Length = 5-5 lines in 2 locations

topics_directory.php 1 location

@@ 72-76 (lines=5) @@
69
        if (array_key_exists($onetopic['topic_id'], $newscountbytopic)) {
70
            $count = $newscountbytopic[$onetopic['topic_id']];
71
        }
72
        if ($onetopic['topic_pid'] != 0) {
73
            $onetopic['prefix'] = str_replace('.', '-', $onetopic['prefix']) . ' ';
74
        } else {
75
            $onetopic['prefix'] = str_replace('.', '', $onetopic['prefix']);
76
        }
77
78
        $tbl_topics[] = array(
79
            'id'          => $onetopic['topic_id'],

blocks/news_top.php 1 location

@@ 682-686 (lines=5) @@
679
    $size       = count($options);
680
    foreach ($topics_arr as $onetopic) {
681
        $sel = '';
682
        if ($onetopic['topic_pid'] != 0) {
683
            $onetopic['prefix'] = str_replace('.', '-', $onetopic['prefix']) . ' ';
684
        } else {
685
            $onetopic['prefix'] = str_replace('.', '', $onetopic['prefix']);
686
        }
687
        for ($i = 14; $i < $size; ++$i) {
688
            if ($options[$i] == $onetopic['topic_id']) {
689
                $sel = " selected='selected'";