From b3e888284622d27c3480548bc336612e56505f0f Mon Sep 17 00:00:00 2001 From: Roland Mas Date: Wed, 10 Feb 2010 08:37:43 +0000 Subject: [PATCH] Accessibility patches by Matthieu Faure / Open-S, first chunk --- .gitattributes | 3 + gforge/www/frs/index.php | 149 ++--- gforge/www/include/Layout.class.php | 347 ++++++++-- gforge/www/include/features_boxes.php | 91 ++- gforge/www/include/html.php | 6 +- gforge/www/include/project_home.php | 322 ++++----- gforge/www/include/user_home.php | 97 ++- gforge/www/include/vote_function.php | 21 +- gforge/www/index_std.php | 16 +- gforge/www/my/index.php | 33 +- gforge/www/news/news_utils.php | 78 ++- gforge/www/project/admin/index.php | 129 ++++ gforge/www/snippet/snippet_utils.php | 2 +- gforge/www/snippet/submit.php | 50 +- gforge/www/softwaremap/tag_cloud.php | 2 +- gforge/www/softwaremap/trove_list.php | 60 +- gforge/www/themes/css/fusionforge.css | 65 ++ gforge/www/themes/gforge/Theme.class.php | 645 +++++++------------ gforge/www/themes/gforge/css/theme-pages.css | 152 +++++ gforge/www/themes/gforge/css/theme.css | 340 +++++----- gforge/www/themes/gforge/js/gforge.js | 9 + 21 files changed, 1532 insertions(+), 1085 deletions(-) create mode 100644 gforge/www/themes/css/fusionforge.css create mode 100644 gforge/www/themes/gforge/css/theme-pages.css create mode 100644 gforge/www/themes/gforge/js/gforge.js diff --git a/.gitattributes b/.gitattributes index e5a7045813..3baf51622d 100644 --- a/.gitattributes +++ b/.gitattributes @@ -3555,6 +3555,7 @@ gforge/www/tabber/example2.html -text gforge/www/tabber/tabber-minimized.js -text gforge/www/tabber/tabber.js -text gforge/www/terms.php -text +gforge/www/themes/css/fusionforge.css -text gforge/www/themes/gforge-classic/images/box-grad.png -text gforge/www/themes/gforge-classic/images/box-topleft.png -text gforge/www/themes/gforge-classic/images/box-topright.png -text @@ -3654,6 +3655,7 @@ gforge/www/themes/gforge-simple-theme/images/logo.png -text gforge/www/themes/gforge/COPYING -text gforge/www/themes/gforge/README.txt -text gforge/www/themes/gforge/Theme.class.php -text +gforge/www/themes/gforge/css/theme-pages.css -text gforge/www/themes/gforge/css/theme.css -text gforge/www/themes/gforge/images/bottomtab-new/middle.gif -text gforge/www/themes/gforge/images/bottomtab-new/selected-middle.gif -text @@ -3715,6 +3717,7 @@ gforge/www/themes/gforge/images/toptab-new/selected-left.gif -text gforge/www/themes/gforge/images/toptab-new/selected-middle.gif -text gforge/www/themes/gforge/images/toptab-new/selected-right.gif -text gforge/www/themes/gforge/images/vert-grad.png -text +gforge/www/themes/gforge/js/gforge.js -text gforge/www/themes/gforge/viewvc/help.css -text gforge/www/themes/gforge/viewvc/help_dirview.html -text gforge/www/themes/gforge/viewvc/help_log.html -text diff --git a/gforge/www/frs/index.php b/gforge/www/frs/index.php index f6eca3055f..8e31da7fb7 100644 --- a/gforge/www/frs/index.php +++ b/gforge/www/frs/index.php @@ -60,21 +60,20 @@ $sql = "SELECT * $res_package = db_query_params( $sql, array($group_id)); $num_packages = db_numrows( $res_package ); - - frs_header(array('title'=>_('Project Filelist'),'group'=>$group_id)); if ( $num_packages < 1) { echo "

"._('No File Packages')."

"; echo "

"._('There are no file packages defined for this project.').""; } else { + echo '

'; - echo '

'._('Below is a list of all files of the project.').' '; + echo '

'._('Below is a list of all files of the project.').' '; if ($release_id) { echo _('The release you have chosen is highlighted.').' '; } echo _('Before downloading, you may want to read Release Notes and ChangeLog (accessible by clicking on release version).').' -

+
'; // check the permissions and see if this user is a release manager. @@ -83,54 +82,41 @@ if ( $num_packages < 1) { $perm =& $cur_group->getPermission(session_get_user()); if ($perm->isReleaseTechnician()) { - echo '

'; - echo _('To create a new release click here.'); + //echo '

'; + echo '

'; + echo _('To create a new release click here.'); echo "

"; } // get unix group name for path $group_unix_name=group_getunixname($group_id); - echo ' -'; - $cell_data=array(); - $cell_data[] = array(_('Package'),'rowspan="2"'); - $cell_data[] = array(_('Release & Notes'),'rowspan="2"'); - $cell_data[] = array(_('Filename'),'rowspan="2"'); - $cell_data[] = array(_('Date'),'colspan="4"'); - - echo $GLOBALS['HTML']->multiTableRow('', $cell_data, TRUE); - - $cell_data=array(); - $cell_data[] = array(_('Size')); - $cell_data[] = array(_('D/L')); - $cell_data[] = array(_('Arch')); - $cell_data[] = array(_('Type')); - - echo $GLOBALS['HTML']->multiTableRow('',$cell_data, TRUE); - $proj_stats['packages'] = $num_packages; $proj_stats['releases'] = 0; $proj_stats['size'] = 0; // Iterate and show the packages for ( $p = 0; $p < $num_packages; $p++ ) { - $cur_style = $GLOBALS['HTML']->boxGetAltRowStyle($p); - $frsPackage = new FRSPackage($cur_group, db_result($res_package,$p,'package_id')); + $frsPackage = new FRSPackage($cur_group, db_result($res_package, $p, 'package_id')); + + $package_name = db_result($res_package, $p, 'name'); + //$package_title = $package_name . ' '; - print ''; + //echo $GLOBALS['HTML']->boxTop($package_title, $package_name); + $package_name_protected = $HTML->toSlug($package_name); + echo '

' . $package_name . '' . $package_monitor . '

'; + // get the releases of the package $res_release = db_query_params ('SELECT * FROM frs_release WHERE package_id=$1 @@ -141,36 +127,16 @@ if ( $num_packages < 1) { $proj_stats['releases'] += $num_releases; if ( !$res_release || $num_releases < 1 ) { - print ''."\n"; + echo '' . _('No releases') . ' + '; } else { // iterate and show the releases of the package for ( $r = 0; $r < $num_releases; $r++ ) { - - $cell_data=array(); - + $package_release = db_fetch_array( $res_release ); + $release_title = util_make_link ( 'frs/shownotes.php?release_id=' . $package_release['release_id'], $package_name.' '.$package_release['name']); + echo $GLOBALS['HTML']->boxTop($release_title, $package_name . '_' . $package_release['name']); - // Highlight the release if one was chosen - if ( $release_id ) { - if ( $release_id == $package_release['release_id'] ) { - $bgstyle = 'class="selected"'; - $cell_data[] = array('  - '.$package_release['name'] .'', - 'colspan="3"'); - } else { - $bgstyle = $cur_style; - $cell_data[] = array(' '.$package_release['name'] .'','colspan="3"'); - } - } else { - $bgstyle = $cur_style; - $cell_data[] = array(' '.$package_release['name'] .'','colspan="3"'); - } - - $cell_data[] = array('  - '.date(_('Y-m-d H:i'), $package_release['release_date'] ) .'', - 'colspan="4" align="center"'); - - print $GLOBALS['HTML']->multiTableRow($bgstyle, $cell_data, FALSE); // get the files in this release.... $res_file = db_query_params("SELECT frs_file.filename AS filename, frs_file.file_size AS file_size, @@ -189,39 +155,56 @@ if ( $num_packages < 1) { @$proj_stats['files'] += $num_files; + $cell_data = array(); + $cell_data[] = _('Filename'); + $cell_data[] = _('Date'); + $cell_data[] = _('Size'); + $cell_data[] = _('D/L'); + $cell_data[] = _('Arch'); + $cell_data[] = _('Type'); + + if ($release_id==$package_release['release_id']) { + echo $GLOBALS['HTML']->listTableTop($cell_data,'',true); + } else { + echo $GLOBALS['HTML']->listTableTop($cell_data); + } + if ( !$res_file || $num_files < 1 ) { - print ''."\n"; + echo ' + '; } else { // now iterate and show the files in this release.... for ( $f = 0; $f < $num_files; $f++ ) { $file_release = db_fetch_array( $res_file ); - - $cell_data=array(); - - $cell_data[] = array('
- '.util_make_link ('/frs/download.php/'.$file_release['file_id'].'/'.$file_release['filename'],$file_release['filename']), - 'colspan=3'); - - $cell_data[] = array(human_readable_bytes($file_release['file_size']),'align="right"'); - $cell_data[] = array( ($file_release['downloads'] ? number_format($file_release['downloads'], 0) : '0'), 'align="right"'); - $cell_data[] = array($file_release['processor']); - $cell_data[] = array($file_release['type']); - - if ( $release_id ) { - if ( $release_id == $package_release['release_id'] ) { - print $GLOBALS['HTML']->multiTableRow($bgstyle, $cell_data,FALSE); - } - } else { - print $GLOBALS['HTML']->multiTableRow($bgstyle, $cell_data, FALSE); - } + + $tmp_col1 = util_make_link ('/frs/download.php/'.$file_release['file_id'].'/'.$file_release['filename'], $file_release['filename']); + $tmp_col2 = date(_('Y-m-d H:i'), $package_release['release_date'] ); + $tmp_col3 = human_readable_bytes($file_release['file_size']); + $tmp_col4 = ($file_release['downloads'] ? number_format($file_release['downloads'], 0) : '0'); + $tmp_col5 = $file_release['processor']; + $tmp_col6 = $file_release['type']; + $proj_stats['size'] += $file_release['file_size']; @$proj_stats['downloads'] += $file_release['downloads']; + + echo '
\n"; + echo ' '."\n"; + echo ' '."\n"; + echo ' '."\n"; + echo ' '."\n"; + echo ' '."\n"; + echo ' '."\n"; + echo ''."\n"; } } + echo $GLOBALS['HTML']->listTableBottom(); + echo $GLOBALS['HTML']->boxBottom(); } } + //echo $GLOBALS['HTML']->boxBottom(); } - +// print statistics for this table datas +/* if ( $proj_stats['size'] ) { print ''."\n"; print '' @@ -234,6 +217,12 @@ if ( $num_packages < 1) { print "

'.db_result($res_package,$p,'name'); - if($frsPackage->isMonitoring()) { - print ' '. - html_image('ic/xmail16w.png','20','20',array('alt'=>_('Stop monitoring this package'))); + $title = db_result($res_package, $p, 'name') . " - " . _('Stop monitoring this package'); + $url = '/frs/monitor.php?filemodule_id='. db_result($res_package, $p, 'package_id') .'&group_id='.db_result($res_package,$p,'group_id').'&stop=1'; + $package_monitor = util_make_link ( $url, $GLOBALS['HTML']->getMonitorPic($title)); } else { - print ' '. - html_image('ic/mail16w.png','20','20',array('alt'=>_('Monitor this package'))); + $title = db_result($res_package, $p, 'name') . " - " . _('Monitor this package'); + $url = '/frs/monitor.php?filemodule_id='. db_result($res_package, $p, 'package_id') .'&group_id='.db_result($res_package,$p,'group_id').'&start=1'; + $package_monitor = util_make_link ( $url, $GLOBALS['HTML']->getMonitorPic($title)); } - - print '

 
  '._('No releases').' 
No Files
 
  '._('No releases').'
' . $tmp_col1 . '' . $tmp_col2 . '' . $tmp_col3 . '' . $tmp_col4 . '' . $tmp_col5 . '' . $tmp_col6 . '
 
'._('Project totals').'
\n\n"; } +*/ + +echo '
'; + +} + frs_footer(); ?> diff --git a/gforge/www/include/Layout.class.php b/gforge/www/include/Layout.class.php index 74db4a5751..6f27887832 100644 --- a/gforge/www/include/Layout.class.php +++ b/gforge/www/include/Layout.class.php @@ -229,9 +229,7 @@ if (isset($params['group']) && $params['group']) {   @@ -245,8 +243,8 @@ if (isset($params['group']) && $params['group']) { @@ -282,7 +280,6 @@ if (isset($params['group']) && $params['group']) { function footerEnd($params) { ?> -
Powered By FusionForge
@@ -317,7 +314,7 @@ if (isset($params['group']) && $params['group']) { - + @@ -342,7 +339,7 @@ if (isset($params['group']) && $params['group']) { - + @@ -386,10 +383,10 @@ if (isset($params['group']) && $params['group']) { * @param array The array of titles * @param array The array of title links */ - function listTableTop ($title_arr,$links_arr=false) { + function listTableTop ($title_arr,$links_arr=false,$selected=false) { $return = '
'.$title.'
'.$title.'
- +
@@ -499,15 +496,15 @@ if (isset($params['group']) && $params['group']) { $selected=array_search(util_make_url ('/admin/'),$TABS_DIRS); } elseif (count($PLUGIN_TABS_DIRS)>0) { foreach ($PLUGIN_TABS_DIRS as $PLUGIN_TABS_DIRS_VALUE) { - if (strstr(getStringFromServer('REQUEST_URI'),$PLUGIN_TABS_DIRS_VALUE)) { - $selected=array_search($PLUGIN_TABS_DIRS_VALUE,$TABS_DIRS); + if (strstr(getStringFromServer('REQUEST_URI'), $PLUGIN_TABS_DIRS_VALUE)) { + $selected=array_search($PLUGIN_TABS_DIRS_VALUE, $TABS_DIRS); break; } } } else { $selected=0; } - echo $this->tabGenerator($TABS_DIRS,$TABS_TITLES,false,$selected,'','100%'); + echo $this->tabGenerator($TABS_DIRS, $TABS_TITLES, false, $selected, ''); } @@ -530,9 +527,9 @@ if (isset($params['group']) && $params['group']) { return ''; } else { $ret = ' - - + '; for ($i = 0; $i < db_numrows($res); $i++) { $group_id = db_result($res, $i, 'group_id'); @@ -550,16 +547,16 @@ if (isset($params['group']) && $params['group']) { $menu = $project->getMenu(); $ret .= ' - '; for ($j = 0; $j < count($menu['dirs']); $j++) { $ret .= ' - '; if ($menu['admindirs'][$j]) { $ret .= ' - '; } @@ -567,7 +564,7 @@ if (isset($params['group']) && $params['group']) { } $ret .= ' - '; + '; } } return $ret; @@ -596,7 +593,7 @@ if (isset($params['group']) && $params['group']) { $menu = $project->getMenu($toptab); - echo $this->tabGenerator($menu['dirs'], $menu['titles'], true, $menu['selected'], 'white', '100%'); + echo $this->tabGenerator($menu['dirs'], $menu['titles'], true, $menu['selected'], 'white'); } function tabGenerator($TABS_DIRS,$TABS_TITLES,$nested=false,$selected=false,$sel_tab_bgcolor='white',$total_width='100%') { @@ -605,13 +602,15 @@ if (isset($params['group']) && $params['group']) { $width=intval((100/$count)); $return = ''; - $return .= ' - - -
- '; +
-
- '; - + print ''; + print ''; + + print ''; + print ''; + if (isset($group_id) && $group_id) { - print ' - - '; + $link_content = html_image('picto_remarques.png','21','21',array('alt'=>_('Advanced search'), 'title'=>_('Advanced search'))); + print ' '.util_make_link ('/search/advanced_search.php?group_id='.$group_id, $link_content, array('class'=>'lnkutility', 'id'=>'advanced-search')); } - print '
-  '; + echo ''; + $parameters = $searchManager->getParameters(); foreach($parameters AS $name => $value) { - print ''; + print ''; } - print ''; - print ''; - - print ' '; - print ''; - print ' '.util_make_link ('/search/advanced_search.php?group_id='.$group_id,_('Advanced search'),array('class'=>'lnkutility')).'
'; + print ''; print ''; - } - + function advancedSearchBox($sectionsArray, $group_id, $words, $isExact) { - // display the searchmask + // display the searchmask print '
-

+

- + '; } -} + + function html_input($name, $id = '', $label = '', $type = 'text', $value = '', $extra_params = '') { + if (!$id) { + $id = $name; + } + $return = '
+ '; + if ($label) { + $return .= ' + '; + } + $return .= ' $extra_params_value) { + $return .= $key . '="' . $extra_params_value . '" '; + } + } + $return .= '/> +
'; + return $return; + } + + function html_checkbox($name, $value, $id = '', $label = '', $checked = '', $extra_params = '') { + if (!$id) { + $id = $name; + } + $return = '
+ '; + $return .= ' $extra_params_value) { + $return .= $key . '="' . $extra_params_value . '" '; + } + } + $return .= '/>'; + if ($label) { + $return .= ' + '; + } + $return .= '
'; + return $return; + } + + function html_text_input_img_submit($name, $img_src, $id = '', $label = '', $value = '', $img_title = '', $img_alt = '', $extra_params = '', $img_extra_params = '') { + if (!$id) { + $id = $name; + } + if (!$img_title) { + $img_title = $name; + } + if (!$img_alt) { + $img_alt = $img_title; + } + $return = '
+ '; + if ($label) { + $return .= ' + '; + } + $return .= ' $extra_params_value) { + $return .= $key . '="' . $extra_params_value . '" '; + } + } + $return .= '/> + $img_extra_params_value) { + $return .= $key . '="' . $img_extra_params_value . '" '; + } + } + $return .= '/> +
'; + return $return; + } + + function html_select($vals, $name, $label = '', $id = '', $checked_val = '', $text_is_value = false, $extra_params = '') { + if (!$id) { + $id = $name; + } + $return = '
+ '; + if ($label) { + $return .= ' + '; + } + $return .= ' +
'; + return $return; + } + + function html_textarea($name, $id = '', $label = '', $value = '', $extra_params = '') { + if (!$id) { + $id = $name; + } + $return = '
+ '; + if ($label) { + $return .= ' + '; + } + $return .= ' +
'; + return $return; + } + + function html_table_top($cols, $summary = '', $class = '', $extra_params = '') { + $return = '
@@ -847,7 +835,7 @@ if (isset($params['group']) && $params['group']) {
 
'; foreach($sectionsArray as $key => $section) { $oldcountlines = $countLines; @@ -982,7 +970,7 @@ if (isset($params['group']) && $params['group']) { $return= '
$extra_params_value) { + $return .= $key . '="' . $extra_params_value . '" '; + } + } + $return .= '>'; + $return .= ''; + $nbCols = count($cols); + for ($i = 0; $i < $nbCols; $i++) { + $return .= ''; + } + $return .= ''; + return $return; + } + + function getMonitorPic($title = '', $alt = '') { + return $this->getPicto('ic/mail16w.png', $title, $alt, '15', '15'); + } + + function getReleaseNotesPic($title = '', $alt = '') { + return $this->getPicto('ic/manual16c.png', $title, $alt, '15', '15'); + } + + /* no picto for download */ + function getDownloadPic($title = '', $alt = '') { + return $this->getPicto('ic/save.png', $title, $alt, '15', '15'); + } + + function getHomePic($title = '', $alt = '') { + return $this->getPicto('ic/home16b.png', $title, $alt); + } + + function getFollowPic($title = '', $alt = '') { + return $this->getPicto('ic/tracker20g.png', $title, $alt); + } + + function getForumPic($title = '', $alt = '') { + return $this->getPicto('ic/forum20g.png', $title, $alt);; + } + + function getDocmanPic($title = '', $alt = '') { + return $this->getPicto('ic/docman16b.png', $title, $alt); + } + + function getMailPic($title = '', $alt = '') { + return $this->getPicto('ic/mail16b.png', $title, $alt); + } + + function getPmPic($title = '', $alt = '') { + return $this->getPicto('ic/taskman20g.png', $title, $alt); + } + + function getScmPic($title = '', $alt = '') { + return $this->getPicto('ic/cvs16b.png', $title, $alt); + } + + function getFtpPic($title = '', $alt = '') { + return $this->getPicto('ic/ftp16b.png', $title, $alt); + } + + function getPicto($url, $title, $alt, $width = '20', $height = '20') { + if (!$alt) { + $alt = $title; + } + return html_image($url, $width, $height, array('title'=>$title, 'alt'=>$alt)); + } + + /** + * toSlug() - protect a string to be used as a link or an anchor + * + * @param string $string the string used as a link or an anchor + * @param string $space the caracter used as a replacement for a space + * @return a protected string with only alphanumeric caracters + */ + function toSlug($string, $space = "-") { + if (function_exists('iconv')) { + $string = @iconv('UTF-8', 'ASCII//TRANSLIT', $string); + } + $string = preg_replace("/[^a-zA-Z0-9- ]/", "-", $string); + $string = strtolower($string); + $string = str_replace(" ", $space, $string); + return $string; + } +} + // Local Variables: // mode: php diff --git a/gforge/www/include/features_boxes.php b/gforge/www/include/features_boxes.php index f7ee40820a..470a0d2091 100644 --- a/gforge/www/include/features_boxes.php +++ b/gforge/www/include/features_boxes.php @@ -13,34 +13,38 @@ require_once $gfcommon.'include/tag_cloud.php'; function show_features_boxes() { GLOBAL $HTML,$sys_use_ratings,$sys_use_frs,$sys_use_project_tags; + // have to echo right now otherwise features boxes top will be at bottom + // echo $HTML->boxTop(_('Features Boxes'), 'Features_Boxes'); + echo '

' . _('Features Boxes') . '

'; + plugin_hook ("features_boxes_top", array()); $return = ''; + if ($sys_use_project_tags) { - $return .= $HTML->boxTop(_('Tag Cloud')); - $return .= '
'; + $return .= $HTML->boxTop(_('Tag Cloud'), 'Tag_Cloud'); $return .= tag_cloud(); - $return .= '
'; - $return .= $HTML->boxMiddle(sprintf(_('%1$s Statistics'), $GLOBALS['sys_name']),0); + $return .= $HTML->boxMiddle(sprintf(_('%1$s Statistics'), $GLOBALS['sys_name']), 'Forge_Statistics'); } else { - $return .= $HTML->boxTop(sprintf(_('%1$s Statistics'), $GLOBALS['sys_name']),0); + $return .= $HTML->boxTop(sprintf(_('%1$s Statistics'), $GLOBALS['sys_name']), 'Forge_Statistics'); } $return .= show_sitestats(); if ($sys_use_frs) { - $return .= $HTML->boxMiddle(_('Top Project Downloads')); + $return .= $HTML->boxMiddle(_('Top Project Downloads'), 'Top_Projects_Downloads'); $return .= show_top_downloads(); } if ($sys_use_ratings) { - $return .= $HTML->boxMiddle(_('Highest Ranked Users')); + $return .= $HTML->boxMiddle(_('Highest Ranked Users'), 'Highest_Ranked_Users'); $return .= show_highest_ranked_users(); } - $return .= $HTML->boxMiddle(_('Most Active This Week')); + $return .= $HTML->boxMiddle(_('Most Active This Week'), 'Most_Active_This_Week'); $return .= show_highest_ranked_projects(); - $return .= $HTML->boxMiddle(_('Recently Registered Projects')); + $return .= $HTML->boxMiddle(_('Recently Registered Projects'), 'Recently_Registered_Projects'); $return .= show_newest_projects(); $hook_params = array () ; $hook_params['returned_text'] = '' ; plugin_hook ("features_boxes_bottom", $hook_params); $return .= $HTML->boxBottom(0); - return $return; + echo $return; + plugin_hook ("features_boxes_bottom", array()); } function show_top_downloads() { @@ -69,15 +73,24 @@ function show_top_downloads() { return _('No Stats Available'); } // print each one - $return = ""; while ($row_topdown = db_fetch_array($res_topdown)) { - if ($row_topdown['downloads'] > 0) - $return .= '(' . number_format($row_topdown['downloads']) . ') ' - . util_make_link_g ($row_topdown['unix_group_name'],$row_topdown['group_id'],$row_topdown['group_name']) - . "
\n"; + if ($row_topdown['downloads'] > 0) { + $t_downloads = number_format($row_topdown['downloads']); + $t_prj_link = util_make_link_g ($row_topdown['unix_group_name'], $row_topdown['group_id'], $row_topdown['group_name']); + + $return .= ''; + $return .= ''; + $return .= ''; + $return .= '\n'; + } } - $return .= '
'.util_make_link ('/top/',_('More')).'
'; - + if ( $return != "" ) { + /* MFaure: test required to deal with a special case encountered on zforge by 20091204 */ + $t_return = $return; + $return = '
' . $cols[$i] . '
' . $t_downloads . '' . $t_prj_link . '
' . $t_return . "
\n"; + } + $return .= '
' . util_make_link ('/top/', _('All the ranking'), array('class' => 'dot-link')) . '
'; + return $return; } @@ -131,7 +144,8 @@ function stats_downloads_total() { function show_sitestats() { global $sys_use_trove; $gforge = new FusionForge(); - $return = _('Hosted Projects').': '; + $return = '

'; + $return .= _('Hosted Projects').': '; if ($sys_use_trove) { $return .= ''; } @@ -139,8 +153,9 @@ function show_sitestats() { if ($sys_use_trove) { $return .= ''; } - $return .= '
'._('Registered Users').': '. - number_format($gforge->getNumberOfActiveUsers()).''; + $return .= "

"; + $return .= _('Registered Users').': '.number_format($gforge->getNumberOfActiveUsers()).''; + $return .= "

\n"; return $return; } @@ -152,14 +167,22 @@ function show_newest_projects() { if (!$res_newproj || db_numrows($res_newproj) < 1) { return _('No Stats Available')." ".db_error(); } else { + + $return .= '' . "\n"; while ( $row_newproj = db_fetch_array($res_newproj) ) { - $return .= "(" . date(_('m/d'),$row_newproj['register_time']) . ") " - . util_make_link_g ($row_newproj['unix_group_name'],$row_newproj['group_id'],$row_newproj['group_name']) - .'
'; + + $t_prj_date = date(_('m/d'),$row_newproj['register_time']); + $t_prj_link = util_make_link_g ($row_newproj['unix_group_name'],$row_newproj['group_id'],$row_newproj['group_name']); + + $return .= ""; + $return .= '"; + $return .= ''; + $return .= "\n"; } + $return .= '
' . $t_prj_date . "' . $t_prj_link . '
'; } - $return .= '
'.util_make_link ('/softwaremap/full_list.php','[ '._('More').' ]').'
'; + $return .= '
'.util_make_link ('/softwaremap/full_list.php', _('All newest projects'), array('class' => 'dot-link')).'
'; return $return; } @@ -178,7 +201,7 @@ function show_highest_ranked_users() { .'
'; } } - $return .= '
'.util_make_link ('/top/topusers.php','[ '._('More').' ]').'
'; + $return .= '
'.util_make_link ('/top/topusers.php', _('All users'), array('class' => 'dot-link')).'
'; return $return; } @@ -189,15 +212,19 @@ function show_highest_ranked_projects() { if (!$result || db_numrows($result) < 1) { return _('No Stats Available')." ".db_error(); } else { - $return=''; + $return = ''; while ($row=db_fetch_array($result)) { - $return .= '(#'.number_format(substr($row['ranking'],0,5),1).') ' - .util_make_link_g ($row['unix_group_name'],$row['group_id'],$row['group_name']) - .'
'; + $t_prj_activity = number_format(substr($row['ranking'],0,5),1); + $t_prj_link = util_make_link_g ($row['unix_group_name'],$row['group_id'],$row['group_name']); + + $return .= ""; + $return .= '"; + $return .= ''; + $return .= "\n"; } - $return .= '
' - .util_make_link ('/top/mostactive.php?type=week','[ '._('More').' ]') - .'
'; + $return .= "
' . $t_prj_activity . "%' . $t_prj_link . '
"; + $return .= '
' . util_make_link ('/top/mostactive.php?type=week', _('All project activities'), array('class' => 'dot-link')) . '
'; + } return $return; } diff --git a/gforge/www/include/html.php b/gforge/www/include/html.php index b1456673a5..942127c5a5 100644 --- a/gforge/www/include/html.php +++ b/gforge/www/include/html.php @@ -110,11 +110,6 @@ function html_abs_image($url, $width, $height, $args) { $return .= ' '.$k.'="'.$v.'"'; } - // ## insert a border tag if there isn't one - if (!isset($args['border'])) { - $return .= ' border="0"'; - } - if (!isset($args['alt'])) { $return .= ' alt=""'; } @@ -732,6 +727,7 @@ function site_user_header($params) { Check to see if logged in */ echo $HTML->header($params); + echo "

" . _('My Personal Page') . "

\n"; echo html_feedback_top((isset($GLOBALS['feedback']) ? $GLOBALS['feedback'] : '')); echo ($HTML->beginSubMenu()); if ($GLOBALS['sys_use_diary']) { diff --git a/gforge/www/include/project_home.php b/gforge/www/include/project_home.php index 3fb88738d9..22bc6a8b1b 100644 --- a/gforge/www/include/project_home.php +++ b/gforge/www/include/project_home.php @@ -22,12 +22,14 @@ site_project_header(array('title'=>$title,'group'=>$group_id,'toptab'=>'home')); // ########################################### end top area // two column deal -?> - - +echo ' +
+
- - - -
- +

'.$project->getPublicName().'

+

'._('Project summary').'

'; + // ########################################## top area, not in box @@ -96,7 +98,7 @@ if ($project->usesStats()) { if ( ($project->usesTracker() && $GLOBALS['sys_use_tracker']) || ($project->usesPm() && $GLOBALS['sys_use_pm']) ) { print sprintf(_(' or Activity'),util_make_url ('/project/report/?group_id='.$group_id)); } - print '
'.sprintf(_('View list of RSS feeds available for this project.'), util_make_url ('/export/rss_project.php?group_id='.$group_id)). ' ' . html_image('ic/rss.png',16,16,array('border'=>'0')); + print '
'.sprintf(_('View list of RSS feeds available for this project.'), util_make_url ('/export/rss_project.php?group_id='.$group_id)). ' ' . html_image('ic/rss.png',16,16,array()); } if($GLOBALS['sys_use_people']) { @@ -125,89 +127,75 @@ $hook_params = array () ; $hook_params['group_id'] = $group_id ; plugin_hook ("project_after_description",$hook_params) ; -?> -
- -' ; // ########################### Developers on this project -echo $HTML->boxTop(_('Project Members')); +echo '' ; +echo $HTML->boxTop(_('Project Members'), 'Project_Members'); $iam_member = false ; if (db_numrows($res_admin) > 0) { - - ?> - :
- '. _('Members').':
'; - } - echo util_make_link_u ($row_admin['user_name'],$row_admin['user_id'],$row_admin['realname']).'
'; - if ($row_admin['user_id'] == user_getid()) - $iam_member = true ; + echo "

\n"; + echo ':
'; + $started_developers = false; + while ($row_admin = db_fetch_array($res_admin)) { + if (trim($row_admin['admin_flags']) != 'A' && !$started_developers) { + $started_developers=true; + echo ''. _('Developers').':
'; } - ?> -


- '; + if ($row_admin['user_id'] == user_getid()) + $iam_member = true ; + } + echo "

\n"; } -?> - -

getUsers(); - echo util_make_link ('/project/memberlist.php?group_id='.$group_id,'['.sprintf(_('View the %1$d Member(s)'),count($members)).']'); ?>

- -getUsers(); +echo '

'; +echo util_make_link ('/project/memberlist.php?group_id='.$group_id,'['.sprintf(_('View the %1$d Member(s)'),count($members)).']'); ?> +echo '

'; if (!$iam_member) { - echo '

'.util_make_link ('/project/request.php?group_id='.$group_id,'['._('Request to join').']').'

'; + echo '

'.util_make_link ('/project/request.php?group_id='.$group_id,_('Request to join')).'

'; } echo $HTML->boxBottom(); -?> -
- -
- -
'; $hook_params = array () ; $hook_params['group_id'] = $group_id ; plugin_hook ("project_before_frs",$hook_params) ; +echo '
'; // ############################# File Releases // CB hide FRS if desired if ($project->usesFRS()) { - echo $HTML->boxTop(_('Latest File Releases')); + echo $HTML->boxTop(_('Latest File Releases'), 'Latest_File_Releases'); $unix_group_name = $project->getUnixName(); echo ' - - - - - - - +
- '._('Package').' - - '._('Version').' - - '._('Date').' - - '._('Notes').' / '._('Monitor').' - - '._('Download').' -
+ + + + + + + '; // @@ -233,7 +221,7 @@ if ($project->usesFRS()) { if (!$res_files || $rows_files < 1) { echo db_error(); // No releases - echo ''; + echo ''; } else { /* @@ -244,62 +232,85 @@ if ($project->usesFRS()) { if (db_result($res_files,$f,'package_id')==db_result($res_files,($f-1),'package_id')) { //same package as last iteration - don't show this release } else { - $rel_date = getdate(db_result($res_files,$f,'release_date')); + $rel_date = getdate (db_result ($res_files, $f, 'release_date')); + $package_name = db_result($res_files, $f, 'package_name'); + $package_release = db_result($res_files,$f,'release_name'); echo ' - - '; + + '; // Releases to display - print ' - - - '; + echo ' + + + + + + '; + } } - } - ?>
+ '._('Package').' + + '._('Version').' + + '._('Date').' + + '._('Notes').' + + '._('Monitor').' + + '._('Download').' +
'._('This Project Has Not Released Any Files').'
'._('This Project Has Not Released Any Files').'
- ' . db_result($res_files,$f,'package_name'). '
+ ' . $package_name . ' + '.db_result($res_files,$f,'release_name') .' - ' . $rel_date["month"] . ' ' . $rel_date["mday"] . ', ' . $rel_date["year"] . ''; - echo html_image('ic/manual16c.png','15','15',array('alt'=>_('Release Notes'))); - echo ' - '; - echo html_image('ic/mail16d.png','15','15',array('alt'=>_('Monitor this package'))); - echo ' - '.util_make_link ('/frs/?group_id=' . $group_id . '&release_id=' . db_result($res_files,$f,'release_id'),_('Download')).'
' + .$package_release.' + ' + . $rel_date["month"] . ' ' . $rel_date["mday"] . ', ' . $rel_date["year"] . + ''; + + // -> notes + // accessibility: image is a link, so alt must be unique in page => construct a unique alt + $tmp_alt = $package_name . " - " . _('Release Notes'); + $link = '/frs/shownotes.php?group_id=' . $group_id . '&release_id=' . db_result($res_files, $f, 'release_id'); + $link_content = $HTML->getReleaseNotesPic($tmp_alt, $tmp_alt); + echo util_make_link ($link, $link_content); + echo ''; + + // -> monitor + $tmp_alt = $package_name . " - " . _('Monitor this package'); + $link = '/frs/monitor.php?filemodule_id=' . db_result($res_files,$f,'package_id') . '&group_id='.$group_id.'&start=1'; + $link_content = $HTML->getMonitorPic($tmp_alt, $tmp_alt); + echo util_make_link ($link, $link_content); + echo ''; + + // -> download + $tmp_alt = $package_name." ".$package_release." - ". _('Download'); + $link_content = $HTML->getDownloadPic($tmp_alt, $tmp_alt); + $t_link_anchor = $HTML->toSlug($package_name)."-".$HTML->toSlug($package_release)."-title-content"; + $link = '/frs/?group_id=' . $group_id . '&release_id=' . db_result($res_files, $f, 'release_id')."#".$t_link_anchor; + echo util_make_link ($link, $link_content); + echo '
-
- -
-boxBottom(); + echo ''; + echo '
' . util_make_link ('/frs/?group_id='.$group_id, _('View All Project Files')) . '
'; + + echo $HTML->boxBottom(); } +echo '
' . "\n"; + $hook_params = array () ; $hook_params['group_id'] = $group_id ; plugin_hook ("project_after_frs",$hook_params) ; -?> -

- - - - -
- -boxTop(_('Public Areas')); + +echo ' + - - + + +
+ '; +echo $HTML->boxTop(_('Public Areas'), 'Public_Areas'); // ################# Homepage Link -print ''; -print html_image('ic/home16b.png','20','20',array('alt'=>_('Home Page'))); -print ' '._('Project Home Page').''; +echo '
'; +echo util_make_link ('http://' . $project->getHomePage(), $HTML->getHomePic(_('Home Page')) . ' ' . _('Project Home Page')); +echo '
+ '; // ################## ArtifactTypes -// CB hide tracker if desired if ($project->usesTracker()) { - print '
'; - print html_image('ic/tracker20g.png','20','20',array('alt'=>_('Tracker'))); - print ' '._('Tracker').''; + echo '
'; + $link_content = $HTML->getFollowPic(_('Tracker')) . ' ' . _('Tracker'); + echo util_make_link ( '/tracker/?group_id=' . $group_id, $link_content); $result=db_query_params ('SELECT agl.*,aca.count,aca.open_count FROM artifact_group_list agl @@ -314,94 +325,101 @@ if ($project->usesTracker()) { if (!$result || $rows < 1) { echo '
'._('There are no public trackers available').''; } else { - echo '
    ' ; - + echo '
      '; for ($j = 0; $j < $rows; $j++) { - echo '
    • ' ; - print util_make_link ('/tracker/?atid='. db_result($result, $j, 'group_artifact_id') . '&group_id='.$group_id.'&func=browse',db_result($result, $j, 'name')) . ' ' ; + echo '
    • '; + echo util_make_link ('/tracker/?atid='. db_result($result, $j, 'group_artifact_id') . '&group_id='.$group_id.'&func=browse',db_result($result, $j, 'name')) . ' ' ; printf(ngettext('(%1$s open / %2$s total)', '(%1$s open / %2$s total)', (int) db_result($result, $j, 'open_count')), (int) db_result($result, $j, 'open_count'), (int) db_result($result, $j, 'count')) .'
      '. db_result($result, $j, 'description'); echo '
    • ' ; } - echo '
    ' ; + echo '
'; } + echo '
'; } // ################## forums if ($project->usesForum()) { - print '
'; - print html_image('ic/forum20g.png','20','20',array('alt'=>_('Forums'))); - print ' '._('Public Forums').' ('; + echo '
'; + $link_content = $HTML->getForumPic('') . ' ' . _('Public Forums'); + echo util_make_link ( '/forum/?group_id=' . $group_id, $link_content); + print ' ('; $messages_count = project_get_public_forum_message_count($group_id); $forums_count = project_get_public_forum_count($group_id); printf(ngettext("%d message","%d messages",$messages_count),$messages_count); print ' in '; printf(ngettext("%d forum","%d forums",$forums_count),$forums_count); print ')' ; + print "\n
"; } // ##################### Doc Manager if ($project->usesDocman()) { - print ' -
- '; - print html_image('ic/docman16b.png','20','20',array('alt'=>_('Documents'))); - print ' '._('DocManager: Project Documentation').''; + echo '
'; + $link_content = $HTML->getDocmanPic('') . ' ' . _('DocManager: Project Documentation'); + print util_make_link( '/docman/?group_id='.$group_id, $link_content); + echo '
'; } // ##################### Mailing lists if ($project->usesMail()) { - print '
'; - print html_image('ic/mail16b.png','20','20',array('alt'=>_('Mailing Lists'))); - print ' '._('Mailing Lists').' '; + echo '
'; + $link_content = $HTML->getMailPic('') . ' ' . _('Mailing Lists'); + print util_make_link( '/mail/?group_id='.$group_id, $link_content); $n = project_get_mail_list_count($group_id); printf(ngettext('(%1$s public mailing list)', '(%1$s public mailing lists)', $n), $n); + echo '
'; } // ##################### Task Manager if ($project->usesPm()) { - print '
'; - print html_image('ic/taskman20g.png','20','20',array('alt'=>_('Task Manager'))); - print ' '._('Task Manager').''; - $result = db_query_params ('SELECT * FROM project_group_list WHERE group_id=$1 AND is_public=1', - array ($group_id)); + echo '
'; + $link_content = $HTML->getPmPic('') . ' ' . _('Task Manager'); + print util_make_link( '/pm/?group_id='.$group_id, $link_content); + + $sql="SELECT * FROM project_group_list WHERE group_id='$group_id' AND is_public=1"; + $result = db_query ($sql); $rows = db_numrows($result); if (!$result || $rows < 1) { echo '
'._('There are no public subprojects available').''; } else { - echo '
    ' ; + echo '
      '; for ($j = 0; $j < $rows; $j++) { echo '
    • ' ; print util_make_link ('/pm/task.php?group_project_id='.db_result($result, $j, 'group_project_id').'&group_id='.$group_id.'&func=browse',db_result($result, $j, 'project_name')); echo '
    • ' ; } - echo '
    ' ; + echo '
'; } + echo '
'; } // ######################### Surveys if ($project->usesSurvey()) { - print '
'; - print html_image('ic/survey16b.png','20','20',array('alt'=>_('Surveys'))); - print ' '._('Surveys').""; - echo ' ('. project_get_survey_count($group_id) .' '._('surveys').')'; + echo '
'; + print html_image('ic/survey16b.png','20','20',array('alt'=>"")) . " "; + print util_make_link( '/survey/?group_id='.$group_id, ' '._('Surveys')); + echo ' ( '. project_get_survey_count($group_id) .' ' . _('surveys').' )'; + echo '
'; } // ######################### SCM if ($project->usesSCM()) { - print '
'; - print html_image('ic/cvs16b.png','20','20',array('alt'=>_('Source Code'))); - print ' '._('SCM Repository').""; + echo '
'; + + $link_content = $HTML->getScmPic('') . ' ' . _('SCM Repository'); + print util_make_link( '/scm/?group_id='.$group_id, $link_content); $hook_params = array () ; $hook_params['group_id'] = $group_id ; plugin_hook ("scm_stats", $hook_params) ; + echo '
'; } // ######################### Plugins @@ -415,10 +433,11 @@ plugin_hook ("project_public_area", $hook_params); // CB hide FTP if desired if ($project->usesFTP()) { if ($project->isActive()) { - print '
'; - print ''; - print html_image('ic/ftp16b.png','20','20',array('alt'=>_('Anonymous FTP Space'))); - print ' '._('Anonymous FTP Space').""; + echo '
'; + + $link_content = $HTML->getFtpPic('') . ' ' . _('Anonymous FTP Space'); + print util_make_link('ftp://' . $project->getUnixName() . '.' . $GLOBALS['sys_default_domain'] . '/pub/'. $project->getUnixName(), $link_content); + echo '
'; } } @@ -426,37 +445,32 @@ if ($project->usesFTP()) { plugin_hook("cal_link_group",$group_id); echo $HTML->boxBottom(); -if ($project->usesNews()) { - // COLUMN BREAK - ?> - -
  +echo ' + + '; - usesNews()) { // ############################# Latest News - - echo $HTML->boxTop(_('Latest News')); - + echo $HTML->boxTop(_('Latest News'), 'Latest_News'); echo news_show_latest($group_id,10,false); - echo $HTML->boxBottom(); } +//echo $HTML->boxBottom(); + +echo '
+ + '; + // // Linked projects (hierarchy) // plugin_hook('project_home_link',$group_id); -?> -
- -header(array('title'=>_('Developer Profile'))); -?> - - - - - - - - - - - - boxBottom(); ?> - - - - - -
+echo $HTML->boxTop(_('Personal Information'), _('Personal Information')); ?> -boxTop(_('Personal Information')); ?> -
- + + + + - + - - + + - +getJabberAddress()) { ?> - + +getPhone()) { ?> - +getFax()) { ?> - + @@ -91,19 +88,26 @@ $HTML->header(array('title'=>_('Developer Profile'))); +
+ + + header(array('title'=>_('Developer Profile')));
getUnixName(); ?>
getTitle() .' '. $user->getRealName(); ?>
: getEmail())); ?>
getJabberAddress(); ?> @@ -65,21 +62,21 @@ $HTML->header(array('title'=>_('Developer Profile'))); getAddress() || $user->getAddress2()) { ?> -
getAddress().'
'.$user->getAddress2(); ?>
getPhone(); ?>
getFax(); ?>
getAddDate()); ?> - +
+ boxMiddle(_('Peer Rating'),false,false); + echo $HTML->boxMiddle(_('Peer Rating'), _('Peer Rating')); + echo ''; if ($user->usesRatings()) { echo vote_show_user_rating($user_id); } else { + echo ''; } + echo '
'; echo _('User chose not to participate in peer rating'); + echo '
'; } if ($sys_use_diary) { - echo $HTML->boxMiddle(_('Diary and Notes')); + echo $HTML->boxMiddle(_('Diary and Notes'), _('Diary and Notes')); /* @@ -114,8 +118,8 @@ $HTML->header(array('title'=>_('Developer Profile'))); $res = db_query_params ('SELECT count(*) from user_diary WHERE user_id=$1 AND is_public=1', array ($user_id)); echo _('Diary/Note entries:').' '.db_result($res,0,0).' -

'.util_make_link ('/developer/diary.php?diary_user='.$user_id,_('View Diary & Notes')).'

-

'; +

'.util_make_link ('/developer/diary.php?diary_user='.$user_id,_('View Diary & Notes')).'

+

'; echo util_make_link ('/developer/monitor.php?diary_user='.$user_id, html_image("ic/check.png",'15','13',array(),0) ._('Monitor this Diary') ) ; @@ -124,14 +128,12 @@ $HTML->header(array('title'=>_('Developer Profile'))); plugin_hook("user_personal_links",$hookparams); } ?> -

-

-

+ boxMiddle(_('Project Info'), _('Project Info')); + // now get listing of groups for that user $res_cat = db_query_params ('SELECT groups.group_name, groups.unix_group_name, @@ -148,39 +150,31 @@ $HTML->header(array('title'=>_('Developer Profile'))); // see if there were any groups if (db_numrows($res_cat) < 1) { ?> -

+

"._('This developer is a member of the following projects:')."

    "; + print "

    "._('This developer is a member of the following projects:')."
     "; while ($row_cat = db_fetch_array($res_cat)) { - print ('

  • ' . util_make_link_g ($row_cat['unix_group_name'],$row_cat['group_id'],$row_cat['group_name']).' ('.$row_cat['role_name'].')
  • '); + print ('
    ' . util_make_link_g ($row_cat['unix_group_name'],$row_cat['group_id'],$row_cat['group_name']).' ('.$row_cat['role_name'].')'); + print "\n"; } - print '

'; + print '

'; } // end if groups -?> -
- -usesRatings() && (!$me || $me->usesRatings())) { + echo '

If you are familiar with this user, please take a moment to rate him/her on the following criteria. Keep in mind, that your rating will be visible to the user and others.

'; + echo '

The '. $GLOBALS['sys_name'] .' Peer Rating system is based on concepts from Advogato. The system has been re-implemented and expanded in a few ways.

'; -printf(_('

If you are familiar with this user, please take a moment to rate him/her on the following criteria. Keep in mind, that your rating will be visible to the user and others.

The %1$s Peer Rating system is based on concepts from Advogato. The system has been re-implemented and expanded in a few ways.

'), $GLOBALS['sys_name']); ?> -
+
getID():0); ?>
- The Peer rating box shows all rating averages (and response levels) for each individual criteria. Due to the math and processing required to do otherwise, these numbers incoporate responses from both "trusted" and "non-trusted" users.

  • The "Sitewide Rank" field shows the user\'s rank compared to all ranked %1$s users.
  • The "Aggregate Score" shows an average, weighted overall score, based on trusted-responses only.
  • The "Personal Importance" field shows the weight that users ratings of other developers will be given (between 1 and 1.5) -- higher rated user\'s responses are given more weight.

If you would like to opt-out from peer rating system (this will affect your ability to both rate and be rated), refer to your account maintenance page. If you choose not to participate, your ratings of other users will be permanently deleted and the \'Peer Rating\' box will disappear from your user page.

'), + The Peer rating box shows all rating averages (and response levels) for each individual criteria. Due to the math and processing required to do otherwise, these numbers incoporate responses from both "trusted" and "non-trusted" users.

  • The "Sitewide Rank" field shows the user\'s rank compared to all ranked %1$s users.
  • The "Aggregate Score" shows an average, weighted overall score, based on trusted-responses only.
  • The "Personal Importance" field shows the weight that users ratings of other developers will be given (between 1 and 1.5) -- higher rated user\'s responses are given more weight.

If you would like to opt-out from peer rating system (this will affect your ability to both rate and be rated), refer to your account maintenance page. If you choose not to participate, your ratings of other users will be permanently deleted and the \'Peer Rating\' box will disappear from your user page.

'), $GLOBALS['sys_name'], util_make_url ("/account/")); @@ -192,14 +186,9 @@ printf(_('

If you are familiar with this user, please take a moment to rate hi

-
+ } -

- -boxBottom(); $HTML->footer(array()); diff --git a/gforge/www/include/vote_function.php b/gforge/www/include/vote_function.php index b3529df137..600f55f20b 100644 --- a/gforge/www/include/vote_function.php +++ b/gforge/www/include/vote_function.php @@ -390,21 +390,26 @@ function vote_show_user_rate_box ($user_id, $by_id=0) { global $USER_RATING_VALUES,$USER_RATING_QUESTIONS,$USER_RATING_POPUP1,$USER_RATING_POPUP2,$USER_RATING_POPUP3,$USER_RATING_POPUP4,$USER_RATING_POPUP5; echo ' - - - '; + +
'; for ($i=1; $i<=count($USER_RATING_QUESTIONS); $i++) { $popup="USER_RATING_POPUP$i"; - if (!isset($prev_vote[$i])) + if (!isset($prev_vote[$i])) { $prev_vote[$i] = ''; - echo ' - '; + } + echo ' + + + + '; } echo ' - +
'. $USER_RATING_QUESTIONS[$i] .':
' - .html_build_select_box_from_arrays($USER_RATING_VALUES,$$popup,"Q_$i",$prev_vote[$i]/*'xzxz'*/,true,'Unrated').'
'. $USER_RATING_QUESTIONS[$i] .':'. html_build_select_box_from_arrays($USER_RATING_VALUES,$$popup,"Q_$i",$prev_vote[$i]/*'xzxz'*/,true,'Unrated').'
+ + +
'; } diff --git a/gforge/www/index_std.php b/gforge/www/index_std.php index 1f86a7b9da..e84b860d9a 100644 --- a/gforge/www/index_std.php +++ b/gforge/www/index_std.php @@ -2,9 +2,10 @@ require_once $gfcommon.'include/FusionForge.class.php'; ?> - -'; + echo ''; } else { - echo ''; + echo ''; foreach ($forums as $f) { $group = $f->getGroup(); if ($group->getID() != $last_group) { @@ -290,7 +291,7 @@ title=""> } echo ' - boxGetAltRowStyle(0) .'>'; $last_group= $group->getID(); @@ -307,7 +308,7 @@ title=""> $order_name_arr=array(); $order_name_arr[]=_('Remove'); $order_name_arr[]=_('Monitored FileModules'); - echo $HTML->listTableTop($order_name_arr,'',$tabcnt); + echo $HTML->listTableTop($order_name_arr); $result=db_query_params ('SELECT groups.group_name,groups.unix_group_name,groups.group_id,frs_package.name,filemodule_monitor.filemodule_id @@ -319,7 +320,7 @@ AND filemodule_monitor.user_id=$2 ORDER BY group_name DESC', user_getid())); $rows=db_numrows($result); if (!$result || $rows < 1) { - echo ''; + echo ''; } else { for ($i=0; $i<$rows; $i++) { if (db_result($result,$i,'group_id') != $last_group) { @@ -327,7 +328,7 @@ AND filemodule_monitor.user_id=$2 ORDER BY group_name DESC', boxGetAltRowStyle($i) .'>'; } echo ' - boxGetAltRowStyle($i) .'>'; $last_group=db_result($result,$i,'group_id'); @@ -344,7 +345,7 @@ AND filemodule_monitor.user_id=$2 ORDER BY group_name DESC', /* Personal bookmarks */ - echo $HTML->boxTop(_('My Bookmarks'),false,false); + echo $HTML->boxTop(_('My Bookmarks'), 'My_Bookmarks'); echo ''._('Add bookmark').'

'; $result = db_query_params ('SELECT bookmark_url, bookmark_title, bookmark_id from user_bookmarks where @@ -358,7 +359,7 @@ user_id=$1 ORDER BY bookmark_title', } else { for ($i=0; $i<$rows; $i++) { echo ' - boxGetAltRowStyle($i) .'>boxGetAltRowStyle($i) .'>'; + echo ''; echo db_error(); } else { for ($i=0; $i<$rows; $i++) { @@ -407,7 +408,7 @@ user_id=$1 ORDER BY bookmark_title', $img="trash.png"; } echo ' - boxGetAltRowStyle($i) .'>boxGetAltRowStyle($i) .'>
-
+ + + -
+

FusionForge

@@ -54,24 +55,25 @@ require_once $gfcommon.'include/FusionForge.class.php';

  • boxTop(_('Latest News')); +echo $HTML->boxTop(_('Latest News'), 'Latest_News'); echo news_show_latest($sys_news_group,5,true,false,false,5); echo $HTML->boxBottom(); ?>
    +
    +
    software_name, $forge->software_version) ; ?> -
    \ No newline at end of file + \ No newline at end of file diff --git a/gforge/www/my/index.php b/gforge/www/my/index.php index 4562b84ed3..33e465b4fc 100644 --- a/gforge/www/my/index.php +++ b/gforge/www/my/index.php @@ -39,8 +39,9 @@ if (!session_loggedin()) { // || $sf_user_hash) { echo site_user_header(array('title'=>sprintf(_('Personal Page For %s'),user_getname()))); $tabcnt=0; ?> + -
    > +
    >
    @@ -53,7 +54,7 @@ title=""> $order_name_arr[]=_('ID'); $order_name_arr[]=_('Priority'); $order_name_arr[]=_('Summary'); - echo $HTML->listTableTop($order_name_arr,'',$tabcnt); + echo $HTML->listTableTop($order_name_arr); $artifactsForUser = new ArtifactsForUser(session_get_user()); $assignedArtifacts =& $artifactsForUser->getAssignedArtifactsByGroup(); @@ -96,7 +97,7 @@ title=""> $order_name_arr[]=_('ID'); $order_name_arr[]=_('Priority'); $order_name_arr[]=_('Summary'); - echo $HTML->listTableTop($order_name_arr,'',$tabcnt); + echo $HTML->listTableTop($order_name_arr); $projectTasksForUser = new ProjectTasksForUser(session_get_user()); $userTasks =& $projectTasksForUser->getTasksByGroupProjectName(); @@ -148,7 +149,7 @@ title=""> $order_name_arr[]=_('ID'); $order_name_arr[]=_('Priority'); $order_name_arr[]=_('Summary'); - echo $HTML->listTableTop($order_name_arr,'',$tabcnt); + echo $HTML->listTableTop($order_name_arr); $artifactsForUser = new ArtifactsForUser(session_get_user()); $submittedArtifacts =& $artifactsForUser->getSubmittedArtifactsByGroup(); if (count($submittedArtifacts) > 0) { @@ -275,13 +276,13 @@ title=""> $order_name_arr=array(); $order_name_arr[]=_('Remove'); $order_name_arr[]=_('Monitored Forums'); - echo $HTML->listTableTop($order_name_arr,'',$tabcnt); + echo $HTML->listTableTop($order_name_arr); $forumsForUser = new ForumsForUser(session_get_user()); $forums = $forumsForUser->getMonitoredForums(); if (count($forums) < 1) { - echo '
    '._('You are not monitoring any forums.').'
    '._('You are not monitoring any forums.').'
    '.util_make_link ('/forum/myforums.php',_('My Monitored Forums')).'
    '.util_make_link ('/forum/myforums.php',_('My Monitored Forums')).'
    boxGetAltRowStyle(0) .'>'.util_make_link ('/forum/forum.php?forum_id='.$f->getID(),$f->getName()).'
    '._('You are not monitoring any files.').'
    '._('You are not monitoring any files.').'
    '.util_make_link_g (db_result($result,$i,'unix_group_name'),db_result($result,$i,'group_id'),db_result($result,$i,'group_name')).'
    boxGetAltRowStyle($i) .'>'.util_make_link ('/frs/?group_id='.db_result($result,$i,'group_id'),db_result($result,$i,'name')).'
    +
    '. @@ -381,7 +382,7 @@ user_id=$1 ORDER BY bookmark_title', $order_name_arr[]=_('Remove'); $order_name_arr[]=_('My Projects'); $order_name_arr[]=_('My Roles'); - echo $HTML->listTableTop($order_name_arr,'',$tabcnt); + echo $HTML->listTableTop($order_name_arr); // Include both groups and foundries; developers should be similarly // aware of membership in either. @@ -396,7 +397,7 @@ user_id=$1 ORDER BY bookmark_title', 'A')) ; $rows=db_numrows($result); if (!$result || $rows < 1) { - echo '
    '._('You\'re not a member of any active projects').'
    '._('You\'re not a member of any active projects').'
    ' ; +
    ' ; echo util_make_link ("/my/rmproject.php?group_id=" . db_result($result,$i,'group_id'), ''._('Delete').'') ; diff --git a/gforge/www/news/news_utils.php b/gforge/www/news/news_utils.php index 87413186c1..beed9b70d1 100644 --- a/gforge/www/news/news_utils.php +++ b/gforge/www/news/news_utils.php @@ -117,8 +117,15 @@ ORDER BY post_date DESC', if (!$result || $rows < 1) { $return .= _('No News Items Found'); $return .= db_error(); + $return .= ""; } else { for ($i=0; $i<$rows; $i++) { + $t_thread_title = db_result($result,$i,'summary'); + $t_thread_url = "/forum/forum.php?forum_id=" . db_result($result,$i,'forum_id'); + $t_thread_author = db_result($result,$i,'realname'); + + $return .= '
    '; + $return .= "\n"; if ($show_summaries && $limit) { //get the first paragraph of the story if (strstr(db_result($result,$i,'details'),'
    ')) { @@ -127,13 +134,8 @@ ORDER BY post_date DESC', } else { $arr=explode("\n",db_result($result,$i,'details')); } - //if the first paragraph is short, and so are following paragraphs, add the next paragraph on - if ((isset($arr[1]))&&(isset($arr[2]))&& (strlen($arr[0]) < 200) && (strlen($arr[1].$arr[2]) < 300) && (strlen($arr[2]) > 5)) { - $summ_txt='
    '. util_make_links( $arr[0].'
    '.$arr[1].'
    '.$arr[2] ); - } else { - $summ_txt='
    '. util_make_links( $arr[0] ); - } - $proj_name='   -   '.util_make_link_g (strtolower(db_result($result,$i,'unix_group_name')),db_result($result,$i,'group_id'),db_result($result,$i,'group_name')); + $summ_txt=util_make_links( $arr[0] ); + $proj_name=util_make_link_g (strtolower(db_result($result,$i,'unix_group_name')),db_result($result,$i,'group_id'),db_result($result,$i,'group_name')); } else { $proj_name=''; $summ_txt=''; @@ -141,25 +143,30 @@ ORDER BY post_date DESC', if (!$limit) { if ($show_forum) { - $return .= '
  • '.util_make_link ('/forum/forum.php?forum_id='. db_result($result,$i,'forum_id'),''. db_result($result,$i,'summary') . ''); + $return .= '

    '.util_make_link ($t_thread_url, $t_thread_title).'

    '; } else { - $return .= '
  • '. db_result($result,$i,'summary') . ''; + $return .= '

    '. $t_thread_title . '

    '; } $return .= '   '. date(_('Y-m-d H:i'),db_result($result,$i,'post_date')).'
  • '; } else { if ($show_forum) { - $return .= util_make_link ('/forum/forum.php?forum_id='. db_result($result,$i,'forum_id'),''. db_result($result,$i,'summary').''); + $return .= '

    '.util_make_link ($t_thread_url, $t_thread_title).'

    '; } else { - $return .= ' - '. db_result($result,$i,'summary') . ''; + $return .= '

    '. $t_thread_title . '

    '; } - if (!$flat) { - $return .= ' -
     '; + $return .= "
    "; + $return .= ''; + $return .= $t_thread_author; + $return .= ''; + $return .= ' - '; + $return .= date(_('Y-m-d H:i'),db_result($result,$i,'post_date')); + $return .= ' - '; + $return .= $proj_name ; + $return .= "
    \n"; + + if ($summ_txt != "") { + $return .= '

    '.$summ_txt.'

    '; } - $return .= '   '. db_result($result,$i,'realname') .' - '. - date(_('Y-m-d H:i'),db_result($result,$i,'post_date')). '' . - $proj_name . $summ_txt; $res2 = db_query_params ('SELECT total FROM forum_group_list_vw WHERE group_forum_id=$1', array (db_result($result,$i,'forum_id'))); @@ -174,12 +181,17 @@ ORDER BY post_date DESC', } else { $comments_txt = _('Comments'); } - - if ($show_forum){ - $return .= '
    (' . $num_comments .' '. $comments_txt . ') ' - .util_make_link ('/forum/forum.php?forum_id='. db_result($result,$i,'forum_id'),'[' . _('Read More/Comment') . ']').'

    '; + + if ($show_forum) { + $link_text = _('Read More/Comment') ; + $extra_params = array( 'class' => 'dot-link', + 'title' => $link_text . ' ' . $t_thread_title); + $return .= "\n"; + $return .= '
    ' . $num_comments .' '. $comments_txt .' '; + $return .= util_make_link ($t_thread_url, $link_text, $extra_params); + $return .= '
    '; } else { - $return .= '
    '; + $return .= ''; } } @@ -189,9 +201,9 @@ ORDER BY post_date DESC', if ($limit) { $limit--; } - } - if ($tail_headlines){ - $return .= '
    '."\n"; + $return .= "\n"; + $return .= '
    '; + $return .= "\n\n"; } if ($group_id != $sys_news_group) { $archive_url=util_make_url ('/news/?group_id='.$group_id); @@ -201,24 +213,20 @@ ORDER BY post_date DESC', if ($tail_headlines != -1) { if ($show_forum) { - $return .= ''; + $return .= '
    ' . util_make_link($archive_url, _('News archive'), array('class' => 'dot-link')) . '
    '; } else { - $return .= '
    ...
    '; + $return .= '
    ...
    '; } } } - if ($allow_submit && $group_id != $sys_news_group) { if(!$result || $rows < 1) { - $return .= '
    '; + $return .= ''; } //you can only submit news from a project now //you used to be able to submit general news - $return .= '
    ' - .util_make_link ('/news/submit.php?group_id='.$group_id,'['._('Submit News').']').'
    '; + $return .= '
    ' . util_make_link ('/news/submit.php?group_id='.$group_id, _('Submit News')).'
    '; } - return $return; } @@ -263,7 +271,7 @@ function news_foundry_latest($group_id=0,$limit=5,$show_summaries=true) { $return .= util_make_link ('/forum/forum.php?forum_id='. db_result($result,$i,'forum_id'),''. db_result($result,$i,'summary') . '') .'
    '. db_result($result,$i,'realname') .' - '. date(_('Y-m-d H:i'),db_result($result,$i,'post_date')) . $proj_name . ' - '. $summ_txt .'
    '; + '. $summ_txt .''; } } return $return; diff --git a/gforge/www/project/admin/index.php b/gforge/www/project/admin/index.php index 809cb41de6..dca17186ff 100644 --- a/gforge/www/project/admin/index.php +++ b/gforge/www/project/admin/index.php @@ -60,6 +60,10 @@ $adminheadertitle=sprintf(_('Project Admin: %1$s'), $group->getPublicName() ); project_admin_header(array('title'=>$adminheadertitle, 'group'=>$group->getID())); ?> + + + + + + + + + boxMiddle(_('Edit Roles')); +echo ''; +echo role_box($group_id,'role_id',''); +echo ''; + +echo '

    '._('Add Role').''; + +// +// Project hierarchy functions + +plugin_hook('admin_project_link',$group_id) ; + + +echo $HTML->boxBottom();?> + + + + +

    + boxTop(_('Misc. Project Information')); ?> @@ -263,6 +267,131 @@ if($sys_use_frs) { boxBottom(); ?> +   + +boxTop(_('Group Members')); + + /* + + Show the members of this project + + */ + + $res_memb = db_query("SELECT users.realname,users.user_id,users.status, + users.user_name,user_group.admin_flags,user_group.role_id + FROM users,user_group + WHERE users.user_id=user_group.user_id + AND user_group.group_id='$group_id' ORDER BY users.lastname,users.firstname"); + + echo ' + + + + + '; + +while ($row_memb=db_fetch_array($res_memb)) { + + if ($row_memb['status']=='P') { + $status = ""._("Pending (P)").""; + } else if ($row_memb['status']=='S') { + $status = ""._("Suspended (S)").""; + } else { + $status = ""; + } + + echo ' + + + + + + + + + '; +} + echo ' + + + + '; + +/* + Add member form +*/ + +?> + + + + + + + + +
    '._('Unix name').''._('Role').''._('Update').''._('Remove').'
    '.$row_memb['realname'].' ('.$row_memb['user_name'].') '.$status.''.role_box($group_id,'role_id',$row_memb['role_id']).'
    '._('Observer').'
    + +boxMiddle(_('Pending Requests')); +$reqs =& get_group_join_requests($group); +if (count($reqs) < 1) { + echo _('No Pending Requests'); +} else { + for ($i=0; $igetUserId()); + if (!$user || !is_object($user)) { + echo "Invalid User"; + } + ?> +
    + + +
    getUnixName(),$user->getId(),$user->getRealName()); ?> + +
    +>>>>>>> MERGE-SOURCE '; - echo ' '; + echo '

    '; } function snippet_footer($params) { diff --git a/gforge/www/snippet/submit.php b/gforge/www/snippet/submit.php index 087011d0b3..49fe70dc46 100644 --- a/gforge/www/snippet/submit.php +++ b/gforge/www/snippet/submit.php @@ -76,59 +76,59 @@ if (session_loggedin()) { snippet_header(array('title'=>_('Snippet submit'))); ?> -

    Give a good description and comment your code so others can read and understand it.

    Note: You can submit a new version of an existing snippet by browsing the library. You should only use this page if you are submitting an entirely new script or function.'); ?> +

    Give a good description and comment your code so others can read and understand it.

    Note: You can submit a new version of an existing snippet by browsing the library. You should only use this page if you are submitting an entirely new script or function.'); ?>

    -
    - - - + + html_input('form_key', '', '', 'hidden', form_generate_key()); + echo $HTML->html_input('post_changes', '', '', 'hidden', 'y'); + echo $HTML->html_input('changes', '', '', 'hidden', 'First Posted Version'); + ?> - - - - - - - - -
    :
    - +
    + html_input('name', '', _('Title') . ' :' . utils_requiredField(), 'text', '', array('size' => '45', 'maxlength' => '60')); ?>
    :
    - +
    + html_textarea('description', '', _('Description') . ' :' . utils_requiredField(), '', array('rows' => '5', 'cols' => '45')); ?>
    :
    - +
    + html_select ($SCRIPT_TYPE, 'type', _('Script Type') . ' :' . utils_requiredField() ); ?> :
    - +
    + html_select ($SCRIPT_LICENSE, 'license', _('License') . ' :'); ?>
    :
    - +
    + html_select ($SCRIPT_LANGUAGE, 'language', _('Language') . ' :' . utils_requiredField()); ?>

    - +
    + html_select ($SCRIPT_CATEGORY, 'category', _('Category') . ' :' . utils_requiredField()); ?>
    :
    - +
    + html_input('version', '', _('Version') . ' :' . utils_requiredField(), 'text', '', array('size' => '10', 'maxlength' => '15')); ?>
    :
    - +
    + html_textarea('code', '', _('Paste the Code Here') . ' :' . utils_requiredField(), '', array('rows' => '30', 'cols' => '85')); ?>
    - -
    - +
    + html_input('submit', '', _('Make sure all info is complete and accurate'), 'submit', _('SUBMIT')); ?>
    diff --git a/gforge/www/softwaremap/tag_cloud.php b/gforge/www/softwaremap/tag_cloud.php index 2ded68511f..b2a3ddd6d2 100644 --- a/gforge/www/softwaremap/tag_cloud.php +++ b/gforge/www/softwaremap/tag_cloud.php @@ -73,7 +73,7 @@ echo ($HTML->subMenu($subMenuTitle, $subMenuUrl)); $selected_tag = getStringFromRequest('tag'); $page = getIntFromRequest('page', 1); -echo '
    ' . tag_cloud(array('selected' => $selected_tag, 'nb_max' => 100)) . '


    '; +echo '
    ' . tag_cloud(array('selected' => $selected_tag, 'nb_max' => 100)) . '

    '; if ($selected_tag) { diff --git a/gforge/www/softwaremap/trove_list.php b/gforge/www/softwaremap/trove_list.php index db32e71597..2e9d0620f7 100644 --- a/gforge/www/softwaremap/trove_list.php +++ b/gforge/www/softwaremap/trove_list.php @@ -79,8 +79,8 @@ $subMenuUrl[] = '/softwaremap/full_list.php'; echo ($HTML->subMenu($subMenuTitle, $subMenuUrl)); -echo' -
    '; +echo '
    ' . "\n"; +echo '

    Arbre des projets

    ' . "\n"; $row_trove_cat = db_fetch_array($res_trove_cat); @@ -146,27 +146,30 @@ print '

    '. (isset($discrim_desc) ? $discrim_desc : '') . '

    '; // ######## two column table for key on right // first print all parent cats and current cat -print ' -\n\n
    '; +print '' . "\n"; +print '' . "\n"; +print '\n"; +print '
    ' . "\n"; + $folders = explode(" :: ",$row_trove_cat['fullpath']); $folders_ids = explode(" :: ",$row_trove_cat['fullpath_ids']); $folders_len = count($folders); + +print "

    "; +print html_image("picto_cat_categorie.png",'32','33',array('alt'=>"")); +print " "; + for ($i=0;$i<$folders_len;$i++) { - for ($sp=0;$sp<($i*2);$sp++) { - print "   "; - } - echo html_image("ic/ofolder15.png",'15','13',array()); - print "  "; // no anchor for current cat if ($folders_ids[$i] != $form_cat) { print util_make_link ('/softwaremap/trove_list.php?form_cat=' .$folders_ids[$i].$discrim_url, $folders[$i] ) ; + print "  >  "; } else { print ''.$folders[$i].''; } - print "
    \n"; } +print "

    "; // print subcategories $res_sub = db_query_params (' @@ -182,19 +185,24 @@ $res_sub = db_query_params (' array ($form_cat)); echo db_error(); +print ""; // ########### right column: root level -print '
    '; +print "'; // here we print list of root level categories, and use open folder for current $res_rootcat = db_query_params (' SELECT trove_cat_id,fullname @@ -205,21 +213,28 @@ $res_rootcat = db_query_params (' array ()); echo db_error(); +print "

    "; print _('Browse By').':'; +print "

    \n"; + +print '
      '; while ($row_rootcat = db_fetch_array($res_rootcat)) { // print open folder if current, otherwise closed // also make anchor if not current print ('
      '); if (($row_rootcat['trove_cat_id'] == $row_trove_cat['root_parent']) || ($row_rootcat['trove_cat_id'] == $row_trove_cat['trove_cat_id'])) { - echo html_image('ic/ofolder15.png','15','13',array()); - print ('  '.$row_rootcat['fullname']."\n"); + print '
    • ' . $row_rootcat['fullname'] . "
    • \n"; } else { - print util_make_link ('/softwaremap/trove_list.php?form_cat=' .$row_rootcat['trove_cat_id'].$discrim_url, - html_image('ic/cfolder15.png','15','13',array()).'  '.$row_rootcat['fullname']); + + print "
    • "; + print util_make_link ('/softwaremap/trove_list.php?form_cat=' .$row_rootcat['trove_cat_id'].$discrim_url, $row_rootcat['fullname']); + print "
    • \n"; } } -print '
    '; +print "\n"; +print "
    \n"; + ?>
    $TROVE_BROWSELIMIT) { // print '

    This listing was produced by the following query: ' // .$query_projlist.''; +echo '

    ' . "\n"; $HTML->footer(array()); diff --git a/gforge/www/themes/css/fusionforge.css b/gforge/www/themes/css/fusionforge.css new file mode 100644 index 0000000000..4050b7eccb --- /dev/null +++ b/gforge/www/themes/css/fusionforge.css @@ -0,0 +1,65 @@ +/* + * Common stylesheet for *all* FusionForge themes + * + * Note to Forge developpers: + * - put as less code here as possible + * + * Note to Themes developpers: + * - don't add CSS to this file; + * - use your own's theme CSS file(s) instead + * + * Final note: this CSS file should be ideally called: + * - after YUI's reset,fonts and base + * - before the theme's own CSS file + * - Warning: font-size must be expressed in % according to YUI's font table http://developer.yahoo.com/yui/fonts/#chart + * + * Matthieu Faure // Open-s.com 2009 december +*/ + + +/* generic classes +----------------------------------------------- */ +.align-left {text-align: left;} +.align-right {text-align: right;} +.align-center {text-align:center;} + +.bgcolor-grey {background-color: #e5e5e5;} +.bgcolor-white {background-color: white;} + +.width-100p100 {width: 100%;} + +.selected {background-color:pink; } + +.skip { + height:0; + width:0; + left:-19000px; + overflow:hidden; + position:absolute; +} + + +/* Tag cloud +----------------------------------------------- */ +.tag1, .tag2, .tag3, .tag4, .tag5 { + outline-style: none; + margin-left: 0.3em; + margin-right: 0.3em; +} + +.tag1 {font-size: 77%;} /* 10px */ +.tag2 {font-size: 93%;} /* 12px */ +.tag3 {font-size: 108%;} /* 14px */ +.tag4 {font-size: 123.1%;} /* 16px */ +.tag5 {font-size: 138.5%;} /* 18px */ + +/* Table layout +----------------------------------------------- */ +.my-layout-table {width: 100%; } +.my-layout-table td {text-align:left; vertical-align:top; } + +/* FRS +----------------------------------------------- */ +#forge-frs .frs-monitor-package { + padding-left:0.5em; +} \ No newline at end of file diff --git a/gforge/www/themes/gforge/Theme.class.php b/gforge/www/themes/gforge/Theme.class.php index ae2e1898d6..7d42865ddf 100644 --- a/gforge/www/themes/gforge/Theme.class.php +++ b/gforge/www/themes/gforge/Theme.class.php @@ -13,20 +13,21 @@ class Theme extends Layout { // Parent constructor $this->Layout(); - $this->COLOR_CONTENT_BACK= '#ffffff'; - $this->COLOR_LTBACK1= '#eeeeef'; - $this->COLOR_LTBACK2= '#fafafa'; - $this->COLOR_SELECTED_TAB= '#e0e0e0'; - $this->COLOR_HTMLBOX_TITLE = '#bbbbbb'; - $this->COLOR_HTMLBOX_BACK = '#eaecef'; - $this->FONT_CONTENT = 'helvetica'; - $this->FONT_HTMLBOX_TITLE = 'helvetica'; - $this->FONTCOLOR_HTMLBOX_TITLE = '#333333'; - $this->FONTCOLOR_CONTENT = '#333333'; - $this->FONTSIZE = 'small'; - $this->FONTSIZE_SMALLER='x-small'; - $this->FONTSIZE_SMALLEST='xx-small'; - $this->FONTSIZE_HTMLBOX_TITLE = 'small'; + $this->imgroot = THEME_DIR.'/images/'; + $this->jsroot = THEME_DIR.'/js/'; + } + + /** + * Layout() - Constructor + */ + function Layout() { + // Constructor for parent class... + if ( file_exists($GLOBALS['sys_custom_path'] . '/index_std.php') ) { + $this->rootindex = $GLOBALS['sys_custom_path'] . '/index_std.php'; + } else { + $this->rootindex = $GLOBALS['gfwww'].'index_std.php'; + } + $this->Error(); } /** @@ -42,144 +43,115 @@ class Theme extends Layout { } print ''; - ?> - - - - - - - - <?php echo $params['title']; ?> - - - headerLink(); ?> - - - - + + + + '. $params['title'] . ' + + '; + + echo $this->headerLink(); + + echo ' + + '; + + $this->headerCSS(); + + echo ' + + + '; + + $this->bodyHeader($params); + } - $this->headerCSS(); -?> - - - - - bodyHeader($params); - } - - function bodyHeader($params){ - global $user_guide; - - ?> -
    - - - - - - -
    '0'))); ?>searchBox(); ?>getRealName()),array('class'=>'userlink')); - echo ' | '; - echo util_make_link ('/account/', _('My Account'),array('class'=>'userlink')); + function bodyHeader($params) { + global $user_guide; + + echo ' + + + + + - - - - - - - - - - - -
    outerTabs($params); ?>
    - - - - - - - - -
    - projectTabs($params['toptab'],$params['group']); - ?> -
    - - - - +
    - +
    + + + '; + echo $this->outerTabs($params); + echo ''; + if (isset($params['group']) && $params['group']) { + echo $this->projectTabs($params['toptab'],$params['group']); + } } function footer($params) { - ?> -
    - - -
    -
    -Powered By FusionForge -
    - - "showsource")); -} -?> - - - - - + + '; + + global $sys_show_source; + if ($sys_show_source) { + global $SCRIPT_NAME; + print util_make_link ('/source.php?file=' . $SCRIPT_NAME, _('Show source'), array ("class" => "showsource")); + } + echo ' + + + '; } - function headerCSS(){ -?> - - - + + + + + '; + + plugin_hook ('cssfile',$this); } function getRootIndex() { @@ -193,23 +165,19 @@ if ($sys_show_source) { * @param bool Whether to echo or return the results * @param string The box background color */ - function boxTop($title) { - return ' - - - - - - - - - - - -
    '.$title.'
    - - - - - - - - - - -
    - - '; + function boxTop($title, $id = '') { + $t_result = ' +
    +
    +
    +
    +

    '. $title .'

    +
    +
    +
    +
    + '; + return $t_result; } /** @@ -218,34 +186,25 @@ if ($sys_show_source) { * @param string Box title * @param string The box background color */ - function boxMiddle($title) { - return ' - -
    '.$title.'
    - '; + function boxMiddle($title, $id = '') { + $t_result =' + +

    '.$title.'

    +
    + '; + return $t_result; } /** * boxBottom() - Bottom HTML box * - * @param bool Whether to echo or return the results */ function boxBottom() { - return ' - -
    -

    - '; + $t_result=' +
    + + '; + return $t_result; } /** @@ -255,9 +214,9 @@ if ($sys_show_source) { */ function boxGetAltRowStyle($i) { if ($i % 2 == 0) { - return ' bgcolor="#EAEAEA"'; + return 'class="bgcolor-white"'; } else { - return ' bgcolor="#E0E0E0"'; + return 'class="bgcolor-grey"'; } } @@ -267,134 +226,32 @@ if ($sys_show_source) { * @param array The array of titles * @param array The array of title links */ - function listTableTop ($title_arr,$links_arr=false) { - $return = ' - - - - - -
    - - '; + function listTableTop ($title_arr,$links_arr=false,$selected=false) { + $return = '
    + '; $count=count($title_arr); if ($links_arr) { for ($i=0; $i<$count; $i++) { $return .= ' - '; + '; } } else { for ($i=0; $i<$count; $i++) { $return .= ' - '; + '; } } return $return.''; } function listTableBottom() { - return '
    '.$title_arr[$i].''.$title_arr[$i].''.$title_arr[$i].''.$title_arr[$i].'
    '; - } - - function outerTabs($params) { - global $sys_use_trove,$sys_use_snippet,$sys_use_people,$sys_use_project_tags,$sys_use_project_full_list; - - $TABS_DIRS[]=util_make_url ('/') ; - $TABS_DIRS[]=util_make_url ('/my/') ; - if ($sys_use_trove || $sys_use_project_tags || $sys_use_project_full_list) { - $TABS_DIRS[]=util_make_url ('/softwaremap/') ; - } - if ($sys_use_snippet) { - $TABS_DIRS[]=util_make_url ('/snippet/') ; - } - if ($sys_use_people) { - $TABS_DIRS[]=util_make_url ('/people/') ; - } - $TABS_TITLES[]=_('Home'); - $TABS_TITLES[]=_('My Page'); - if ($sys_use_trove || $sys_use_project_tags || $sys_use_project_full_list) { - $TABS_TITLES[]=_('Projects'); - } - if ($sys_use_snippet) { - $TABS_TITLES[]=_('Code Snippets'); - } - if ($sys_use_people) { - $TABS_TITLES[]=_('Project Openings'); - } - // outermenu hook - $PLUGIN_TABS_DIRS = Array(); - $hookParams['DIRS'] = &$PLUGIN_TABS_DIRS; - $hookParams['TITLES'] = &$TABS_TITLES; - plugin_hook ("outermenu", $hookParams) ; - $TABS_DIRS = array_merge($TABS_DIRS, $PLUGIN_TABS_DIRS); - - $user_is_super=false; - $selected = 0 ; - if (session_loggedin()) { - $projectmaster =& group_get_object(GROUP_IS_MASTER); - $projectstats =& group_get_object(GROUP_IS_STATS); - $permmaster =& $projectmaster->getPermission( session_get_user() ); - $permstats =& $projectstats->getPermission( session_get_user() ); - - if ($permmaster->isAdmin()) { - $user_is_super=true; - $TABS_DIRS[]=util_make_url ('/admin/') ; - $TABS_TITLES[]=_('Admin'); - } - if ($permstats->isMember()) { - $TABS_DIRS[]=util_make_url ('/reporting/') ; - $TABS_TITLES[]=_('Reporting'); - } - } - if(isset($params['group']) && $params['group']) { - // get group info using the common result set - $project =& group_get_object($params['group']); - if ($project && is_object($project)) { - if ($project->isError()) { - - } elseif (!$project->isProject()) { - - } else { - if (isset ($GLOBALS['sys_noforcetype']) && $GLOBALS['sys_noforcetype']) { - $TABS_DIRS[]=util_make_url ('/project/?group_id='. $params['group']) ; - } else { - $TABS_DIRS[]=util_make_url ('/projects/'.$project->getUnixName().'/') ; - } - $TABS_TITLES[]=$project->getPublicName(); - $selected=count($TABS_DIRS)-1; - } - } - } elseif (strstr(getStringFromServer('REQUEST_URI'),util_make_url ('/my/')) || strstr(getStringFromServer('REQUEST_URI'),'/account/') || - strstr(getStringFromServer('REQUEST_URI'),util_make_url ('/themes/')) ) { - $selected=array_search(util_make_url ('/my/'), $TABS_DIRS); - } elseif (strstr(getStringFromServer('REQUEST_URI'),util_make_url ('softwaremap'))) { - $selected=array_search(util_make_url ('/softwaremap/'), $TABS_DIRS); - } elseif (strstr(getStringFromServer('REQUEST_URI'),util_make_url ('/snippet/'))) { - $selected=array_search(util_make_url ('/snippet/'), $TABS_DIRS); - } elseif (strstr(getStringFromServer('REQUEST_URI'),util_make_url ('/people/'))) { - $selected=array_search(util_make_url ('/people/'), $TABS_DIRS); - } elseif (strstr(getStringFromServer('REQUEST_URI'),util_make_url ('/reporting/'))) { - $selected=array_search(util_make_url ('/reporting/'),$TABS_DIRS); - } elseif (strstr(getStringFromServer('REQUEST_URI'),util_make_url ('/admin/')) && $user_is_super) { - $selected=array_search(util_make_url ('/admin/'),$TABS_DIRS); - } elseif (count($PLUGIN_TABS_DIRS)>0) { - foreach ($PLUGIN_TABS_DIRS as $PLUGIN_TABS_DIRS_VALUE) { - if (strstr(getStringFromServer('REQUEST_URI'),$PLUGIN_TABS_DIRS_VALUE)) { - $selected=array_search($PLUGIN_TABS_DIRS_VALUE,$TABS_DIRS); - break; - } - } - } else { - $selected=0; - } - if (!$this->COLOR_SELECTED_TAB) { - $this->COLOR_SELECTED_TAB= '#e0e0e0'; - } - echo $this->tabGenerator($TABS_DIRS,$TABS_TITLES,false,$selected,$this->COLOR_SELECTED_TAB,'100%'); - + return ' +
    '; } @@ -403,12 +260,15 @@ if ($sys_show_source) { $width=intval((100/$count)); $return = ' + + - -
    - '; - + if ($total_width != '100%') { + $return .= 'style="width:' . $total_width . ';"'; + } + $return .= ">\n"; + $return .= ''; + $folder = $this->imgroot.($nested ? 'bottomtab-new/' : 'toptab-new/'); for ($i=0; $i<$count; $i++) { @@ -427,91 +287,68 @@ if ($sys_show_source) { } $clear_img = $this->imgroot.'clear.png'; + + $return .= "\n"; + + // left part + $return .= '', $middle_img, $clear_img, $tab_height ); - $return .= sprintf( - '', $middle_img, $css_class, $TABS_DIRS[$i], $TABS_TITLES[$i]); - - // if the next tab is not last, insert a separator - if ($i < $count-1) { - $return .= sprintf( - '', $separ_img, $clear_img, $tab_height ); - } + $return .= ' class="nested"'; } - else { - $tab_height = TOP_TAB_HEIGHT; - - $return .= sprintf( - '', $left_img, $clear_img, $tab_height ); - - $return .= sprintf( - '', $middle_img, $css_class, $TABS_DIRS[$i], $TABS_TITLES[$i]); - - // if the next tab is not selected, close this tab - if ($selected != $i+1) { - $return .= sprintf( - '', $right_img, $clear_img, $tab_height ); - } + $return .= '>' . "\n"; + $return .= ''; + $return .= '' . "\n"; + $return .= '' . "\n"; + + // middle part + $return .= ''; - } - $return .= - ''; - if ($end_cols > 0) { - $return .= - ''; - } - */ - - $return .= ''; - - return $return.' -
    ' . "\n"; + $return .= ' - - - %s - - - - - - %s - - - ' . "\n"; + $return .= ' 0) { - $return .= - ' - - - - - -
    + $return .= '>'; + $return .= ''.$TABS_TITLES[$i].'' . "\n"; + $return .= ''; + $return .= '' . "\n"; + $return .= '' . "\n"; + + // right part + // if the next tab is not selected, close this tab + if ($selected != $i+1) { + $return .= '' . "\n"; + $return .= ' -'; + return $return; } function searchBox() { @@ -529,50 +366,39 @@ if ($sys_show_source) { } print ' -

    '; } @@ -600,7 +426,7 @@ if ($sys_show_source) {
    ' - .$this->createUnderSections($sectionsArray).' + .$this->createUnderSections($sectionsArray).' '; @@ -621,9 +447,9 @@ if ($sys_show_source) { '; } - + function createUnderSections($sectionsArray) { - global $group_subsection_names; + global $group_subsection_names; $countLines = 0; foreach ($sectionsArray as $section) { if(is_array($section)) { @@ -657,7 +483,7 @@ if ($sys_show_source) { } else { $countLines += 3; } - + if ($countLines >= $break) { //if the next block is so large that shifting it to the next column hits the breakpoint better //the second part of statement (behind &&) proofs, that no 4th column is added @@ -667,10 +493,12 @@ if ($sys_show_source) { } } - $return .= ' -
    - -
    + $return .= ' + +
    + + +
    '.$group_subsection_names[$key].'' .' ' @@ -683,7 +511,7 @@ if ($sys_show_source) { if (!is_array($section)) { $return .= ' '; } else @@ -706,7 +534,7 @@ if ($sys_show_source) { } } } - + return $return.'
    '; @@ -747,9 +575,9 @@ if ($sys_show_source) { $return = ''; for ($i=0; $i<$count; $i++) { - $return .= util_make_link ($links_arr[$i], $title_arr[$i]) . ' | '; + $return .= util_make_link ($links_arr[$i], $title_arr[$i]) . ' | '; } - $return .= util_make_link ($links_arr[$i], $title_arr[$i]); + $return .= util_make_link ($links_arr[$i], $title_arr[$i]); return $return; } @@ -827,14 +655,13 @@ if ($sys_show_source) { * getThemeIdFromName() * * @param string the dirname of the theme - * @return integer the theme id + * @return integer the theme id */ function getThemeIdFromName($dirname) { $res=db_query_params ('SELECT theme_id FROM themes WHERE dirname=$1', array($dirname)); return db_result($res,0,'theme_id'); } - } // Local Variables: diff --git a/gforge/www/themes/gforge/css/theme-pages.css b/gforge/www/themes/gforge/css/theme-pages.css new file mode 100644 index 0000000000..c64e01b3e7 --- /dev/null +++ b/gforge/www/themes/gforge/css/theme-pages.css @@ -0,0 +1,152 @@ +/* + * Stylesheet for FusionForge default theme. + * 2009 Matthieu FAURE // Open-S: global clean-up + * + * CONTENT: all page-related styles + * ======================================================== + */ + +/* + * PAGE: home page + * ======================================================== + */ + +/* =bd (main body) +----------------------------------------------- */ +#bd td { + vertical-align: top; + padding: 5px; +} + +#bd-col1 { + width: 65%; +} + +#bd-col2 { + width: 35%; +} + +#title-home-page { + text-align: center; +} + +#Latest_News h3 { + margin-top: 0px; + margin-bottom: 0px; + font-weight: bold; +} + +#Latest_News em { + padding-left: 1em; +} + +/* remove inherited background-image */ +#title_Features_Boxes { + display: none; +} + +#Features_Boxes { + background-image: none; +} + +#Features_Boxes #title_Associated_Forges { + margin-top: 0; +} + +#Associated_Forges td { + padding-right: 1em; +} + +#Associated_Forges .align-right { + text-align: right; +} + +#Recently_Registered_Projects td { + padding: 0.2em; +} + +#search_associated_forges { + float: left; + margin-top: 5px; + margin-bottom: 5px; +} + +#search_associated_forges_submit { + margin-top: 6px; + padding-left: 5px; +} + +/* + * PAGE: project home + * ======================================================== + */ +#project-summary-and-devs { + margin-top: 0.5em; +} + +#file-releases { + margin: 0 0.5em; +} + +/* + * PAGE: frs + * ======================================================== + */ +.frs-table-files { + width: 100%; + margin: 0 0 2.5em 0; +} + +.frs-table-files th { + background: #e8dfd4; +} + +.frs-table-files tr { + border-bottom: solid 1px #c9c9c9; +} + +.frs-table-files th, +.frs-table-files td { + vertical-align:middle; +} + +.frs-table-files h3 { + margin:0; +} + +#forge-frs .blue-box { + padding-top: 2em; + padding-bottom: 2em; +} + +#forge-frs h2 { + padding-top: 1em; +} + +#forge-frs h3 { + font-size: small; +} + +#forge-frs .box-surround { + margin: 0 0.5em 0.5em 2em; +} + +#forge-frs .box-content { + padding-left: 2em; +} + +#forge-frs .listTable { + margin:0; +} + +#forge-frs .listTable td { + width: 12%; +} + +/* + * PAGE: user_home (eg: http://fusionforge/user/) + * ======================================================== + */ +#user-profile-homepage { + +} diff --git a/gforge/www/themes/gforge/css/theme.css b/gforge/www/themes/gforge/css/theme.css index 8ed650524d..310d12154d 100644 --- a/gforge/www/themes/gforge/css/theme.css +++ b/gforge/www/themes/gforge/css/theme.css @@ -1,100 +1,108 @@ /* - * Stylesheet for SAP Forge theme. + * Stylesheet for FusionForge default theme. + * 2009 Matthieu FAURE // Open-S: global clean-up + * + * CONTENT: all generic styles (not page-related) + * ======================================================== */ -BODY { - margin-top: 0em; - margin-left: 0em; - margin-right: 0em; - margin-bottom: 0em; - color: rgb(68, 68, 68); - background-color: rgb(247, 247, 247); - font-family: arial, helvetica, sans-serif; - font-size: small; -} - -form { margin: 0; } - -img { border: 0; } - -a { - text-decoration: none; - color: rgb(1, 73, 144); -} - -/* -a:link { - color: #0000be -} -a:visited { - color: #0000be +/* HTML elements */ +body {color: rgb(68, 68, 68); background-color: rgb(247, 247, 247); } +form {margin:0; } +img {border:0; } +h1 {margin:0; } + +a {text-decoration:none; color:rgb(1, 73, 144); } +a:hover {text-decoration: underline; color: rgb(247, 0, 0); } +a.userlink {color: white; } +a.userlink:hover {text-decoration: underline; color: white;} +a.userlink:visited {text-decoration: none; color: white; } +th, td {text-align:left; border:none; } +#mydoc {text-align: left;} + +/* =header */ +#header { + background: rgb(66, 69, 82) url("../images/header/top-middle.gif") top left repeat-x; + font-size:77%; + margin: 0; } - -a:active { +#header td {padding:0; } +#header p, +#header a { + color: white; + font-weight: bold; } -*/ - -a:hover { - text-decoration: underline; - color: rgb(247, 0, 0); +#header-col1 { + padding:0; +} +#header-col2 { + padding:0; + text-align:center; } - -a.userlink { - font-size: 13px; - font-family: arial,verdana,helvetica,sans-serif; - color: white; +#header-col3 { + padding: 0 1em 0 0; + text-align:right; } -a.userlink:hover { - text-decoration: underline; - color: white; +/* =searchBox */ +#searchBox div { + text-align:center; } -a.userlink:visited { - text-decoration: none; - color: white; +/* =tabGenerator */ +.tabGenerator {font-weight:bold; margin:0; } +.tabGenerator td {padding:0; } +.tabGenerator .tg-left div div { + background: 0 0 url(/themes/gforge/images/toptab-new/left.gif) no-repeat; + display: block; + width: 3px; + height: 30px; } - -h1,h2,h3,h4,h5,h6 { - font-family: verdana, arial, helvetica, sans-serif; +.tabGenerator .tg-middle { + vertical-align: middle; } - -h1 { - font-size: x-large; +.tabGenerator .tg-middle div div { + background: url(/themes/gforge/images/toptab-new/middle.gif); + text-align:center; + vertical-align: middle; + height: 30px; } - -h2 { - font-size: large; +.tabGenerator .tg-right div div { + background: 0 0 url(/themes/gforge/images/toptab-new/right.gif) no-repeat; + display: block; + width: 9px; + height: 30px; } -h3 { - font-size: medium; -} +.tabGenerator .tg-left div div.nested {width:5px; } +.tabGenerator .tg-right div div.nested {width:2px; } +.tabGenerator .tg-left div div.nested, +.tabGenerator .tg-middle div div.nested, +.tabGenerator .tg-right div div.nested {height: 22px; padding-top:0.5em; } -h4 { - font-size: small; -} +.tabGenerator .tg-left div.selected div {background-image:url(/themes/gforge/images/toptab-new/selected-left.gif); } +.tabGenerator .tg-middle div.selected div {background-image: url(/themes/gforge/images/toptab-new/selected-middle.gif); } +.tabGenerator .tg-right div.selected div {background-image: url(/themes/gforge/images/toptab-new/selected-right.gif)} -h5 { - font-size: x-small; -} +.tabGenerator .tg-left div div.nested {background:0 0 url(/themes/gforge/images/bottomtab-new/middle.gif); } +.tabGenerator .tg-middle div div.nested {background:url(/themes/gforge/images/bottomtab-new/middle.gif); } +.tabGenerator .tg-right div div.nested {background: 0 0 url(/themes/gforge/images/bottomtab-new/separator.gif); } -h6 { - font-size: xx-small; -} +.tabGenerator .tg-left div.selected div.nested {background:0 0 url(/themes/gforge/images/bottomtab-new/selected-middle.gif); } +.tabGenerator .tg-middle div.selected div.nested{background:url(/themes/gforge/images/bottomtab-new/selected-middle.gif); } +.tabGenerator .tg-right div.selected div.nested {background: 0 0 url(/themes/gforge/images/bottomtab-new/selected-separator.gif); } -pre,tt { - font-family: courier, sans-serif -} +/* set padding only for non nested tabs */ +.tabGenerator .tg-middle div div a {display:block; padding-top: 0.5em;} +.tabGenerator .tg-middle div div.nested a {display:inline;} -/* the style of the label on a box title */ -.titlebar { - text-decoration: none; - font-weight: bold; -} +/* set white color only for nested + selected tab */ +.tabGenerator .tg-middle div div.nested a {color: white;} +.tabGenerator .tg-middle div.selected div.nested a {color: rgb(1,73,144);;} +/* =tabber */ .topTab, a.topTab, a.topTab:visited, a.topTab:hover, -.topTabSelected, a.topTabSelected, a.topTabSelected:visited, +.topTabSelected, a.topTabSelected, a.topTabSelected:visited, a.topTabSelected:hover { text-decoration: none; font-weight: bold; @@ -120,18 +128,6 @@ a.bottomTabSelected:hover { font-size: 0.9em; } -/* header style */ -.header { - background: rgb(66, 69, 82) url("../images/header/top-middle.gif") top left - repeat-x; - /* padding-right: 1em; */ - padding-top: 0; - padding-bottom: 0; - padding-left: 0; - margin: 0 0 0 0; - vertical-align: top; -} - .topLeft { vertical-align: top; text-align: left; @@ -142,46 +138,6 @@ a.bottomTabSelected:hover { text-align: right; } -.header form { - padding: 0 0 0 0; - margin: 0 0 0 0; - border-width: 0; -} - -/* -.header h1 { - position: absolute; - top: 0; - left: 0; - margin: 0; - font-size: 2px; - height: 8px; - z-index: 100; -} - -.header h1 a { - display: block; - width: 300px; - height: 55px; - background: transparent url("../images/header/top-logo.png") no-repeat; - text-indent: -700em; - text-decoration: none; -} -*/ - -.header p,.header a { - color: white; - font-family: arial, helvetica, sans-serif; - font-weight: bold; - font-size: 0.8em; -} - -.mainCanvas { - width: 100%; - padding: 0.6em 0.6em 0.6em 0.6em ; - border: 0; -} - .pane { color: rgb(112, 112, 112); background-color: white; @@ -192,7 +148,7 @@ a.bottomTabSelected:hover { But do not hide them in the print stylesheet! --------------------------------------------------*/ .tabberlive .tabbertabhide { - display:none; + display:none; } /*-------------------------------------------------- @@ -202,58 +158,52 @@ a.bottomTabSelected:hover { .tabber { } .tabberlive { - margin-top:1em; + margin-top:1em; } /*-------------------------------------------------- ul.tabbernav = the tab navigation list li.tabberactive = the active tab --------------------------------------------------*/ -ul.tabbernav -{ - margin:0; - padding: 3px 0; - border-bottom: 1px solid #778; +ul.tabbernav { + margin:0; + padding: 3px 0; + border-bottom: 1px solid #778; } -ul.tabbernav li -{ - list-style: none; - margin: 0; - display: inline; +ul.tabbernav li { + list-style: none; + margin: 0; + display: inline; } -ul.tabbernav li a -{ - padding: 3px 0.5em; - margin-left: 3px; - border: 1px solid #778; - border-bottom: none; - background: #D0D0D0; - text-decoration: none; +ul.tabbernav li a { + padding: 3px 0.5em; + margin-left: 3px; + border: 1px solid #778; + border-bottom: none; + background: #D0D0D0; + text-decoration: none; } ul.tabbernav li a:link { color: #333333; } ul.tabbernav li a:visited { color: #667; } -ul.tabbernav li a:hover -{ - color: #000; - background: #FED620; - border-color: #227; +ul.tabbernav li a:hover { + color: #000; + background: #FED620; + border-color: #227; } -ul.tabbernav li.tabberactive a -{ - background-color: #fff; - border-bottom: 1px solid #fff; +ul.tabbernav li.tabberactive a { + background-color: #fff; + border-bottom: 1px solid #fff; } -ul.tabbernav li.tabberactive a:hover -{ - color: #000; - background: white; - border-bottom: 1px solid white; +ul.tabbernav li.tabberactive a:hover { + color: #000; + background: white; + border-bottom: 1px solid white; } /*-------------------------------------------------- @@ -261,27 +211,17 @@ ul.tabbernav li.tabberactive a:hover Add style only after the tabber interface is set up (.tabberlive) --------------------------------------------------*/ .tabberlive .tabbertab { - padding:5px; - border:1px solid #aaa; - border-top:0; - - /* If you don't want the tab size changing whenever a tab is changed - you can set a fixed height */ - - /* height:200px; */ - - /* If you set a fix height set overflow to auto and you will get a - scrollbar when necessary */ - - /* overflow:auto; */ + padding:5px; + border:1px solid #aaa; + border-top:0; } /* If desired, hide the heading since a heading is provided by the tab */ .tabberlive .tabbertab h2 { - display:none; + display:none; } .tabberlive .tabbertab h3 { - display:none; + display:none; } /* Example of using an ID to set different styles for the tabs on the page */ @@ -290,7 +230,51 @@ ul.tabbernav li.tabberactive a:hover .tabberlive#tab2 { } .tabberlive#tab2 .tabbertab { - height:200px; - overflow:auto; + height:200px; + overflow:auto; +} + +.field-holder { + clear: both; } +/* Boxes (top / middle / bottom) +----------------------------------------------- */ +.box-surround { + margin-bottom: 1em; +} + +.box-title-left { + background-image: url(../images/box-topleft.png); + background-repeat: no-repeat; + background-position: top left; +} + +.box-title-right { + background-image: url(../images/box-topright.png); + background-repeat: no-repeat; + background-position: top right; +} + +.box-title-content { + background-image: url(../images/box-grad.png); + margin: 0 0.5em; + padding: 0.2em 0.1em 0.1em; +} + +.box-content { + background-image: url(../images/vert-grad.png); + padding: 0.5em; +} + +.box-middle { + background-image: url(../images/box-grad.png); + margin: 0; + padding: 0.2em 0.5em 0.1em; +} + +/* =ft (footer) +----------------------------------------------- */ +#ft { + text-align:center; +} diff --git a/gforge/www/themes/gforge/js/gforge.js b/gforge/www/themes/gforge/js/gforge.js new file mode 100644 index 0000000000..3207f8bc5a --- /dev/null +++ b/gforge/www/themes/gforge/js/gforge.js @@ -0,0 +1,9 @@ +function admin_window(adminurl) { + AdminWin = window.open( adminurl, 'AdminWindow','scrollbars=yes,resizable=yes, toolbar=yes, height=400, width=400, top=2, left=2'); + AdminWin.focus(); +} + +function help_window(helpurl) { + HelpWin = window.open( helpurl,'HelpWindow','scrollbars=yes,resizable=yes,toolbar=no,height=400,width=600'); +} + -- 2.30.2