File:  [mozdev] / cdn / www / bug.html
Revision 1.29: download - view: text, annotated - select for diffs - revision graph
Mon Mar 3 15:47:16 2003 UTC (16 years, 2 months ago) by cdn
Branches: MAIN
CVS tags: HEAD
bug.html a tweak to far

    1: <h5 class="page-header">Bugs</h5>
    2: 
    3: <ul>
    4: <li>Enter a 
    5: <a href="http://www.mozdev.org/bugs/enter_bug.cgi?product=cdn">new bug</a>
    6:  for cdn
    7: </li>
    8: <li>View <a href="http://mozdev.org/bugs/buglist.cgi?email1=&amp;emailtype1=substring&amp;emailassigned_to1=1&amp;email2=&amp;emailtype2=substring&amp;emailreporter2=1&amp;bugidtype=include&amp;bug_id=&amp;changedin=&amp;votes=&amp;chfieldfrom=&amp;chfieldto=Now&amp;chfieldvalue=&amp;product=cdn&amp;short_desc=&amp;short_desc_type=allwordssubstr&amp;long_desc=&amp;long_desc_type=allwordssubstr&amp;bug_file_loc=&amp;bug_file_loc_type=allwordssubstr&amp;field0-0-0=noop&amp;type0-0-0=noop&amp;value0-0-0=&amp;cmdtype=doit&amp;order=Bug+Number">all bugs</a> 
    9: <li>See all <a href="http://mozdev.org/bugs/buglist.cgi?bug_status=UNCONFIRMED&amp;bug_status=NEW&amp;bug_status=ASSIGNED&amp;bug_status=REOPENED&amp;email1=&amp;emailtype1=substring&amp;emailassigned_to1=1&amp;email2=&amp;emailtype2=substring&amp;emailreporter2=1&amp;bugidtype=include&amp;bug_id=&amp;changedin=&amp;votes=&amp;chfieldfrom=&amp;chfieldto=Now&amp;chfieldvalue=&amp;product=cdn&amp;short_desc=&amp;short_desc_type=allwordssubstr&amp;long_desc=&amp;long_desc_type=allwordssubstr&amp;bug_file_loc=&amp;bug_file_loc_type=allwordssubstr&amp;field0-0-0=noop&amp;type0-0-0=noop&amp;value0-0-0=&amp;cmdtype=doit&amp;order=Bug+Number">open bugs</a></li>
   10: <li>Search by Bug Number<br><br>
   11: <form action="http://mozdev.org/bugs/show_bug.cgi" method="get"><input type="submit" value="Find">
   12: <input size="6" name="id"></form>
   13: </li>
   14: </ul><?php $doNotCapitalise = 1; // $project='mozdev'; $project = 'optimoz'; 
   15: 
   16: //$hiding_BZ_h4 = 1;
   17: //$bug_component = array('gesture', 'radial');
   18: //$comp_desc = array('Mouse Gestures', 'Radial Context');
   19: 
   20: ?>
   21: 
   22: <?php
   23: 
   24: // $Id: bug.html,v 1.29 2003/03/03 15:47:16 cdn Exp $
   25: // $cvsId: bug.html,v 1.23 2003/03/03 10:29:59 cdn Exp svc$
   26: 
   27:   require(PHP_INC.CONNECT);
   28: 
   29:   $product   = ucwords($project);
   30: 
   31:   if ( $doNotCapitalise )
   32:     $product = $project;
   33:   
   34:   if ( ! $hiding_BZ_h4 )
   35:     print '<h4 id="BZ-h4">Latest bugs filed for ' . $product . "</h4>\n\n";
   36: 
   37:   $id             = "bug_id";
   38:   $desc           = "short_desc";
   39:   $res            = "resolution";
   40:   $table          = "bugs";
   41:   $target         = "product";
   42: 
   43:   if (!isset($amount))
   44:     $amount       = 10;
   45: 
   46:   $bug_url        = "http://" . HOST . "/bugs/show_bug.cgi?id=";
   47: 
   48:   $component      = 'component';
   49: 
   50:   if ( !isset($bug_component) )
   51:     $bug_component[0] = '';
   52: 
   53:   $k = count($bug_component);
   54: 
   55:  for ($j=0; $j < $k; ++$j)
   56:  {
   57:   $query          = " SELECT $id, $desc, $component, $res
   58:                       FROM $table
   59:                       WHERE $target='$product'
   60:                       AND $component LIKE '%" . $bug_component[$j] . "%'
   61:                       ORDER BY $id DESC
   62:                       LIMIT $amount
   63:                     ";
   64: 
   65:   $my_result      = mysql_query($query, $connect);
   66: 
   67:   $e              = mysql_error();
   68:   if($e)
   69:     print  "ERROR:latest_bugs: $e"; 
   70: 
   71:   $row            = mysql_num_rows($my_result);
   72: 
   73:   if ( $k > 1 || $hiding_BZ_h4 )
   74:     if ( empty($comp_desc[$j]) )
   75:       print '<h4 class="BZ-component-h4">' . mysql_result($my_result, 0, $component) . "</h4>\n";
   76:     else
   77:       print '<h4 class="BZ-component-h4">' . $comp_desc[$j] . "</h4>\n";
   78: 
   79:   print '<table class="BZ-table" cellspacing="2" cellpadding="2" border="0">' . "\n";
   80: 
   81:   print "<thead>\n<tr>\n";
   82:   print '<th class="BZ-th-bug">Bug #</th>';
   83:   print '<th class="BZ-th-desc">Description</th>' . "\n\n";
   84:   print "</tr>\n</thead>\n";
   85: 
   86:   print "<tbody>\n";
   87:   for($i=0; $i<$row; $i++) {
   88:     $printstrike = false;
   89:     print "<tr>\n<td>\n";
   90:     $bug_id =  mysql_result($my_result, $i, $id);
   91:     $strike =  mysql_result($my_result, $i, $res);
   92:     if ($strike == "FIXED" || $strike == "INVALID" || $strike=="DUPLICATE")
   93:       $printstrike = true;
   94:     if ($printstrike)
   95:       print "<strike>";
   96:     print "<a href=\"$bug_url$bug_id\">";
   97:     print $bug_id;
   98:     print "</a>";
   99:     if ($printstrike)
  100:       print "</strike>";
  101:     print "\n</td>\n<td>\n";
  102:     print htmlspecialchars (  mysql_result($my_result, $i, $desc),ENT_QUOTES);
  103:     print "</td>\n</tr>\n";
  104:   }
  105:   print "</tbody>\n";
  106:   print "</table>\n";
  107:  }
  108: 
  109: ?>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>