Annotation of cdn/www/bug.html, revision 1.11

1.1       cdn         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>
1.6       cdn         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>
1.1       cdn        10: <li>Search by Bug Number<br><br>
1.6       cdn        11: <form action="http://mozdev.org/bugs/show_bug.cgi" method="get"><input type="submit" value="Find">
                     12: <input size="6" name="id"></form>
1.1       cdn        13: </li>
1.9       cdn        14: </ul><?php $doNotCapitalise = 0; $project='mozdev'; //$project = 'optimoz'; ?>
1.1       cdn        15: 
                     16: <?php
                     17: 
1.11    ! cdn        18: // $Id: bug.html,v 1.10 2003/02/28 21:50:22 cdn Exp $
1.1       cdn        19: 
                     20:   require(PHP_INC.CONNECT);
                     21: 
                     22:   $id             = "bug_id";
                     23:   $desc           = "short_desc";
                     24:   $res            = "resolution";
                     25:   $table          = "bugs";
                     26:   $target         = "product";
1.11    ! cdn        27:   $amount         = 40;
1.1       cdn        28:   $bug_url        = "http://mozdev.org/bugs/show_bug.cgi?id=";
                     29: 
1.2       cdn        30:   $component      = 'component';      
                     31:   
1.1       cdn        32:   $product        = ucwords($project);
                     33: 
1.6       cdn        34:   $query          = " SELECT $id, $desc, $component, $res
1.1       cdn        35:                       FROM $table
1.6       cdn        36:                       WHERE $target='$product'
                     37:                       GROUP BY $component
                     38:                       ORDER BY $id DESC
                     39:                       LIMIT $amount
1.1       cdn        40:                     ";
                     41: 
                     42:   $my_result      = mysql_query($query, $connect);
                     43: 
                     44:   $e              = mysql_error();
                     45:   if($e)
                     46:     print  "ERROR:latest_bugs: $e"; 
                     47: 
                     48:   $row            = mysql_num_rows($my_result);
                     49: 
1.2       cdn        50:   if ( $doNotCapitalise )
                     51:     $product = $project;
                     52:   
1.9       cdn        53:   print '<h4 id="BZ-h4">Latest bugs filed for ' . $product . "</h4>\n\n";
1.6       cdn        54: 
                     55:   print '<table cellspacing="2" cellpadding="2" border=0>' . "\n";
                     56: 
1.1       cdn        57:   print "<thead>\n<tr>\n";
1.3       cdn        58:   print '<th bgcolor="#990000"><font color="#ffffff">Bug #</font></th>';
                     59:   print '<th bgcolor="#FF9900">Component</th>' . "\n\n";
1.2       cdn        60:   print '<th bgcolor="#FF9900">Description</th>' . "\n\n";
1.1       cdn        61:   print "</tr>\n</thead>\n";
1.2       cdn        62: 
1.1       cdn        63:   print "<tbody>\n";
                     64:   for($i=0; $i<$row; $i++) {
                     65:     $printstrike = false;
                     66:     print "<tr>\n<td>\n";
                     67:     $bug_id =  mysql_result($my_result, $i, $id);
                     68:     $strike =  mysql_result($my_result, $i, $res);
                     69:     if ($strike == "FIXED" || $strike == "INVALID" || $strike=="DUPLICATE")
                     70:       $printstrike = true;
                     71:     if ($printstrike)
                     72:       print "<strike>";
                     73:     print "<a href=\"$bug_url$bug_id\">";
                     74:     print $bug_id;
                     75:     print "</a>";
                     76:     if ($printstrike)
                     77:       print "</strike>";
1.3       cdn        78:     print "\n</td>\n<td>\n";
1.5       cdn        79: //    print htmlspecialchars (  mysql_result($my_result, $i, $component),ENT_QUOTES);
                     80:     print mysql_result($my_result, $i, $component);
1.1       cdn        81:     print "\n</td>\n<td>\n";
                     82:     print htmlspecialchars (  mysql_result($my_result, $i, $desc),ENT_QUOTES);
                     83:     print "</td>\n</tr>\n";
                     84:   }
                     85:   print "</tbody>\n";
                     86:   print "</table>\n\n";
                     87: 
1.7       cdn        88: ?>

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