Browse the code

 

Differences between 602 and 603 on /.
Number of edited files: 2 (0 added, 0 deleted and 2 modified)
Revision 603

About 25 days and 8 hours ago.

* Made the project menu lighter
Added file(s) Deleted file(s) Modified file(s)

 

Old New Code
103
103
            $url = $this->logo;
104
104

                                        
105
105
        $this->pagemenu = '<ul>
106
 
        <li><a href="project/'.$this->dbname.'" '.((!isset($this->page[3])) ? 'class="current"' : '').' />'.i18n('Project').'</a></li>';
 
106
        <li><a href="project/'.$this->dbname.'" '.((!isset($this->page[3]) || in_array($this->page[3], array('news', 'doc', 'statistics'))) ? 'class="current"' : '').' />'.i18n('Project').'</a></li>';
107
107

                                        
108
108
        if ($this->views['timeline'] == 'TRUE')
109
109
            $this->pagemenu .= '<li><a href="project/'.$this->dbname.'/timeline" '.((isset($this->page[3]) && $this->page[3] == 'timeline') ? 'class="current"' : '').' />'.i18n('Timeline').'</a></li>';
110
110

                                        
111
 
        if ($this->views['news'] == 'TRUE')
112
 
            $this->pagemenu .= '<li><a href="project/'.$this->dbname.'/news" '.((isset($this->page[3]) && $this->page[3] == 'news') ? 'class="current"' : '').' />'.i18n('News').'</a></li>';
113
 

                                    
114
111
        if ($this->views['download'] == 'TRUE')
115
112
            $this->pagemenu .= '<li><a href="project/'.$this->dbname.'/download" '.((isset($this->page[3]) && $this->page[3] == 'download') ? 'class="current"' : '').' />'.i18n('Download').'</a></li>';
116
113

                                        
120
117
        if ($this->views['roadmap'] == 'TRUE')
121
118
            $this->pagemenu .= '<li><a href="project/'.$this->dbname.'/roadmap" '.((isset($this->page[3]) && in_array($this->page[3], array('bugs', 'roadmap'))) ? 'class="current"' : '').' >'.i18n('Tasks').(($opentickets > 0) ? '&nbsp;<span class="info">'.$opentickets.'</span></a></li>' : '</a></li>');
122
119

                                        
123
 
        if ($this->views['doc'] == 'TRUE')
124
 
            $this->pagemenu .= '<li><a href="project/'.$this->dbname.'/doc" '.((isset($this->page[3]) && $this->page[3] == 'doc') ? 'class="current"' : '').' />'.i18n('Documentation').'</a></li>';
125
 

                                    
126
120
        if ($this->views['i18n'] == 'TRUE')
127
121
            $this->pagemenu .= '<li><a href="project/'.$this->dbname.'/i18n" '.((isset($this->page[3]) && $this->page[3] == 'i18n') ? 'class="current"' : '').' />'.i18n('Internationalization').'</a></li>';
128
122

                                        
129
123
        if ($this->views['forum'] == 'TRUE')
130
124
            $this->pagemenu .= '<li><a href="project/'.$this->dbname.'/forum" '.((isset($this->page[3]) && $this->page[3] == 'forum') ? 'class="current"' : '').' />'.i18n('Discussions').(($messages_total > 0) ? '&nbsp;<span class="info">'.$messages_total.'</span>' : '').'</a></li>';
131
125

                                        
132
 
        if ($this->views['statistics'] == 'TRUE')
133
 
            $this->pagemenu .= '<li><a href="project/'.$this->dbname.'/statistics" '.((isset($this->page[3]) && $this->page[3] == 'statistics') ? 'class="current"' : '').' />'.i18n('Statistics').'</a></li>';
134
 

                                    
135
126
        if ($this->ct_session->isLogged())
136
127
        {
137
128
            if (is_affiliation($_SESSION['id'], $this->id, $this->ct_db) ||
148
139
                else
149
140
                    $this->pagemenu .= 'edit/';
150
141

                                        
151
 
                $this->pagemenu .= $this->dbname.'">'.i18n('Edit this project').'</a></li>';
 
142
                $this->pagemenu .= $this->dbname.'"><i class="fas fa-edit fa-fw"></i> '.i18n('Edit').'</a></li>';
152
143
            }
153
144
        }
154
145
        $this->pagemenu .= '</ul>';
156
147
        $additional = '';
157
148
        if (isset($this->page[3]))
158
149
        {
159
 
            if ($this->page[3] == 'timeline')
 
150
            if (in_array($this->page[3], array('news', 'doc', 'statistics')))
160
151
                $additional = '
161
152
                <div id="page_menu">
162
153
                  <ul>
 
154
                    <li><a href="project/'.$this->dbname.'" '.(!isset($this->page[3]) ? 'class="current"' : '').'>'.i18n('Homepage').'</a></li>
 
155
                    '.(($this->views['news'] == 'TRUE') ? '<li><a href="project/'.$this->dbname.'/news" '.(($this->page[3] == 'news') ? 'class="current"' : '').'>'.i18n('News').'</a></li>' : '').'
 
156
                    '.(($this->views['doc'] == 'TRUE') ? '<li><a href="project/'.$this->dbname.'/doc" '.(($this->page[3] == 'doc') ? 'class="current"' : '').'>'.i18n('Documentation').'</a></li>' : '').'
 
157
                    '.(($this->views['statistics'] == 'TRUE') ? '<li><a href="project/'.$this->dbname.'/statistics" '.(($this->page[3] == 'statistics') ? 'class="current"' : '').'>'.i18n('Statistics').'</a></li>' : '').'
 
158
                  </ul>
 
159
                </div>';
 
160
            elseif ($this->page[3] == 'timeline')
 
161
                $additional = '
 
162
                <div id="page_menu">
 
163
                  <ul>
163
164
                    <li><a href="project/'.$this->dbname.'/timeline" '.(($_GET == array()) ? 'class="current"' : '').'>'.i18n('Everything').'</a></li>
164
165
                    <li><a href="project/'.$this->dbname.'/timeline/?download=1&news=1" '.(($_GET == array('download' => '1', 'news' => '1')) ? 'class="current"' : '').'>'.i18n('Official updates').'</a></li>
165
166
                    <li><a href="project/'.$this->dbname.'/timeline/?bugs=1&bugs-updates=1" '.(($_GET == array('bugs' => '1', 'bugs-updates' => '1')) ? 'class="current"' : '').'>'.i18n('Tasks').'</a></li>
176
177
                    <li><a href="project/'.$this->dbname.'/bugs/add" '.((isset($this->page[4]) && $this->page[4] == 'add') ? 'class="current"' : '').'>'.i18n('Create a ticket').'</a></li>
177
178
                  </ul>
178
179
                </div>';
 
180
            /* TODO: move this.
179
181
            elseif ($this->page[3] == 'doc')
180
182
            {
181
183
                if (empty($this->page[4]))
194
196
                  </ul>
195
197
                </div>';
196
198
            }
 
199
            */
197
200
            elseif ($this->page[3] == 'forum')
198
201
                $additional = '
199
202
                <div id="page_menu">
205
208
                    <li><a href="project/'.$this->dbname.'/forum/add" '.((isset($this->page[4]) && $this->page[4] == 'add') ? 'class="current"' : '').'>'.i18n('Create a topic').'</a></li>
206
209
                  </ul>
207
210
                </div>';
 
211
            /* TODO: move this.
208
212
            elseif ($this->page[3] == 'statistics')
209
213
                $additional = '
210
214
                <div id="page_menu">
213
217
                    <li><a href="project/'.$this->dbname.'/forum/statistics/sourcecode" '.((isset($this->page[5]) && $this->page[5] == 'sourcecode') ? 'class="current"' : '').'>'.i18n('Source code').'</a></li>
214
218
                  </ul>
215
219
                </div>';
 
220
            */
216
221
            else
217
222
                $additional = '<div id="page_nomenu">&nbsp;</div>';
218
 

                                    
219
 

                                    
220
 

                                    
221
223
        }
222
224
        else
223
 
            $additional = '<div id="page_nomenu">&nbsp;</div>';
 
225
            $additional = '
 
226
                <div id="page_menu">
 
227
                  <ul>
 
228
                    <li><a href="project/'.$this->dbname.'" class="current">'.i18n('Homepage').'</a></li>
 
229
                    <li><a href="project/'.$this->dbname.'/news">'.i18n('News').'</a></li>
 
230
                    <li><a href="project/'.$this->dbname.'/doc">'.i18n('Documentation').'</a></li>
 
231
                    <li><a href="project/'.$this->dbname.'/statistics">'.i18n('Statistics').'</a></li>
 
232
                  </ul>
 
233
                </div>';
224
234

                                        
225
235

                                        
226
236
        return array(// Module menu
227
237

                                        

 

Old New Code
315
315

                                        
316
316
#header_menu ul li a {
317
317
  display: block;
318
 
  padding: 20px 10px 10px 10px;
 
318
  padding: 20px 20px 10px 20px;
319
319
  font-size: 1.0em;
320
320
  color: {color_700};
321
321
}
355
355
#content #page_menu {
356
356
  background-color: {color_200};
357
357
  margin-left: -12%;
 
358
  padding-left: 12%;
358
359
  text-align: center;
359
360
  border-bottom: 1px {color_300} solid;
360
361
}
361
362