enter_bug.cgi 18.8 KB
Newer Older
1 2
#!/usr/bonsaitools/bin/perl -w
# -*- Mode: perl; indent-tabs-mode: nil -*-
terry%netscape.com's avatar
terry%netscape.com committed
3
#
4 5 6 7 8 9 10 11 12 13
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
terry%netscape.com's avatar
terry%netscape.com committed
14
# The Original Code is the Bugzilla Bug Tracking System.
15
# 
terry%netscape.com's avatar
terry%netscape.com committed
16
# The Initial Developer of the Original Code is Netscape Communications
17 18 19
# Corporation. Portions created by Netscape are Copyright (C) 1998
# Netscape Communications Corporation. All Rights Reserved.
# 
terry%netscape.com's avatar
terry%netscape.com committed
20
# Contributor(s): Terry Weissman <terry@mozilla.org>
21
#                 Dave Miller <justdave@syndicomm.com>
22
#                 Joe Robins <jmrobins@tgix.com>
terry%netscape.com's avatar
terry%netscape.com committed
23

24 25 26 27 28 29 30 31 32 33 34

########################################################################
#
# enter_bug.cgi
# -------------
# Displays bug entry form. Bug fields are specified through popup menus, 
# drop-down lists, or text fields. Default for these values can be passed
# in as parameters to the cgi.
#
########################################################################

35 36
use diagnostics;
use strict;
terry%netscape.com's avatar
terry%netscape.com committed
37

38
require "CGI.pl";
39

40 41 42 43 44 45 46 47 48 49 50
# Shut up misguided -w warnings about "used only once".  "use vars" just
# doesn't work for me.

sub sillyness {
    my $zz;
    $zz = $::unconfirmedstate;
    $zz = @::legal_opsys;
    $zz = @::legal_platform;
    $zz = @::legal_priority;
    $zz = @::legal_severity;
}
51

52 53 54 55 56 57 58 59 60
# I've moved the call to confirm_login up to here, since if we're using bug
# groups to restrict bug entry, we need to know who the user is right from
# the start.  If that parameter is turned off, there's still no harm done in
# doing it now instead of a bit later.  -JMR, 2/18/00
# Except that it will cause people without cookies enabled to have to log
# in an extra time.  Only do it here if we really need to.  -terry, 3/10/00
if (Param("usebuggroupsentry")) {
    confirm_login();
}
61 62 63

if (!defined $::FORM{'product'}) {
    GetVersionTable();
64 65 66 67 68 69 70 71
    my @prodlist;
    foreach my $p (sort(keys %::versions)) {
        if (defined $::proddesc{$p} && $::proddesc{$p} eq '0') {
            # Special hack.  If we stuffed a "0" into proddesc, that means
            # that disallownew was set for this bug, and so we don't want
            # to allow people to specify that product here.
            next;
        }
72 73 74 75 76 77 78 79
        if(Param("usebuggroupsentry")
           && GroupExists($p)
           && !UserInGroup($p)) {
          # If we're using bug groups to restrict entry on products, and
          # this product has a bug group, and the user is not in that
          # group, we don't want to include that product in this list.
          next;
        }
80 81
        push(@prodlist, $p);
    }
82 83 84 85 86 87 88 89 90 91 92 93
    if (0 == @prodlist) {
        print "Content-type: text/html\n\n";
        PutHeader("No Products Available");

        print "Either no products have been defined to enter bugs against ";
        print "or you have not been given access to any.  Please email ";
        print "<A HREF=\"mailto:" . Param("maintainer") . "\">";
        print Param("maintainer") . "</A> if you feel this is in error.<P>\n";

        PutFooter();
        exit;
    } elsif (1 < @prodlist) {
94
        print "Content-type: text/html\n\n";
95 96 97 98 99
        PutHeader("Enter Bug");
        
        print "<H2>First, you must pick a product on which to enter\n";
        print "a bug.</H2>\n";
        print "<table>";
100
        foreach my $p (@prodlist) {
101 102 103
# removed $::proddesc{$p} eq '0' check and UserInGroup($p) check from here
# because it's redundant.  See the foreach loop above that created @prodlist.
# 1/13/01 - dave@intrec.com
104
            print "<tr><th align=right valign=top><a href=\"enter_bug.cgi?product=" . url_quote($p) . "\">$p</a>:</th>\n";
105
            if (defined $::proddesc{$p}) {
106
                print "<td valign=top>$::proddesc{$p}</td>\n";
107
            }
108
            print "</tr>";
109
        }
110
        print "</table>\n";
111
        PutFooter();
112
        exit;
113
    }
114
    $::FORM{'product'} = $prodlist[0];
115 116
}

117
my $product = $::FORM{'product'};
terry%netscape.com's avatar
terry%netscape.com committed
118

119
confirm_login();
terry%netscape.com's avatar
terry%netscape.com committed
120

121
print "Content-type: text/html\n\n";
terry%netscape.com's avatar
terry%netscape.com committed
122

123 124 125 126 127 128 129 130 131 132
sub formvalue {
    my ($name, $default) = (@_);
    if (exists $::FORM{$name}) {
        return $::FORM{$name};
    }
    if (defined $default) {
        return $default;
    }
    return "";
}
terry%netscape.com's avatar
terry%netscape.com committed
133

134 135 136 137
sub pickplatform {
    my $value = formvalue("rep_platform");
    if ($value ne "") {
        return $value;
terry%netscape.com's avatar
terry%netscape.com committed
138
    }
139
    if ( Param('usebrowserinfo') ) {
140
        for ($ENV{'HTTP_USER_AGENT'}) {
141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175
        #PowerPC
            /\(.*PowerPC.*\)/i && do {return "Macintosh";};
            /\(.*PPC.*\)/ && do {return "Macintosh";};
            /\(.*AIX.*\)/ && do {return "Macintosh";};
        #Intel x86
            /\(.*[ix0-9]86.*\)/ && do {return "PC";};
        #Versions of Windows that only run on Intel x86
            /\(.*Windows 9.*\)/ && do {return "PC";};
            /\(.*Win9.*\)/ && do {return "PC";};
            /\(.*Windows 3.*\)/ && do {return "PC";};
            /\(.*Win16.*\)/ && do {return "PC";};
        #Sparc
            /\(.*sparc.*\)/ && do {return "Sun";};
            /\(.*sun4.*\)/ && do {return "Sun";};
        #Alpha
            /\(.*Alpha.*\)/i && do {return "DEC";};
        #MIPS
            /\(.*IRIX.*\)/i && do {return "SGI";};
            /\(.*MIPS.*\)/i && do {return "SGI";};
        #68k
            /\(.*68K.*\)/ && do {return "Macintosh";};
            /\(.*680[x0]0.*\)/ && do {return "Macintosh";};
        #ARM
#            /\(.*ARM.*\) && do {return "ARM";};
        #Stereotypical and broken
            /\(.*Macintosh.*\)/ && do {return "Macintosh";};
            /\(.*Mac OS [89].*\)/ && do {return "Macintosh";};
            /\(Win.*\)/ && do {return "PC";};
            /\(.*Windows NT.*\)/ && do {return "PC";};
            /\(.*OSF.*\)/ && do {return "DEC";};
            /\(.*HP-?UX.*\)/i && do {return "HP";};
            /\(.*IRIX.*\)/i && do {return "SGI";};
            /\(.*(SunOS|Solaris).*\)/ && do {return "Sun";};
        #Braindead old browsers who didn't follow convention:
            /Amiga/ && do {return "Macintosh";};
176
        }
terry%netscape.com's avatar
terry%netscape.com committed
177
    }
178 179
    # default
    return "Other";
terry%netscape.com's avatar
terry%netscape.com committed
180 181
}

182

terry%netscape.com's avatar
terry%netscape.com committed
183

184 185
sub pickversion {
    my $version = formvalue('version');
186 187

    if ( Param('usebrowserinfo') ) {
188 189 190 191
        if ($version eq "") {
            if ($ENV{'HTTP_USER_AGENT'} =~ m@Mozilla[ /]([^ ]*)@) {
                $version = $1;
            }
terry%netscape.com's avatar
terry%netscape.com committed
192 193 194
        }
    }
    
195 196
    if (lsearch($::versions{$product}, $version) >= 0) {
        return $version;
terry%netscape.com's avatar
terry%netscape.com committed
197
    } else {
198 199 200 201
        if (defined $::COOKIE{"VERSION-$product"}) {
            if (lsearch($::versions{$product},
                        $::COOKIE{"VERSION-$product"}) >= 0) {
                return $::COOKIE{"VERSION-$product"};
terry%netscape.com's avatar
terry%netscape.com committed
202 203 204
            }
        }
    }
205
    return $::versions{$product}->[0];
terry%netscape.com's avatar
terry%netscape.com committed
206 207 208
}


209 210 211 212
sub pickcomponent {
    my $result =formvalue('component');
    if ($result ne "" && lsearch($::components{$product}, $result) < 0) {
        $result = "";
terry%netscape.com's avatar
terry%netscape.com committed
213
    }
214
    return $result;
terry%netscape.com's avatar
terry%netscape.com committed
215 216 217
}


218 219 220
sub pickos {
    if (formvalue('op_sys') ne "") {
        return formvalue('op_sys');
terry%netscape.com's avatar
terry%netscape.com committed
221
    }
222
    if ( Param('usebrowserinfo') ) {
223
        for ($ENV{'HTTP_USER_AGENT'}) {
224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252
            /\(.*IRIX.*\)/ && do {return "IRIX";};
            /\(.*OSF.*\)/ && do {return "OSF/1";};
            /\(.*Linux.*\)/ && do {return "Linux";};
            /\(.*SunOS 5.*\)/ && do {return "Solaris";};
            /\(.*SunOS.*\)/ && do {return "SunOS";};
            /\(.*HP-?UX.*\)/ && do {return "HP-UX";};
            /\(.*BSD\/OS.*\)/ && do {return "BSDI";};
            /\(.*FreeBSD.*\)/ && do {return "FreeBSD";};
            /\(.*OpenBSD.*\)/ && do {return "OpenBSD";};
            /\(.*NetBSD.*\)/ && do {return "NetBSD";};
            /\(.*BeOS.*\)/ && do {return "BeOS";};
            /\(.*AIX.*\)/ && do {return "AIX";};
            /\(.*IBM.*\)/ && do {return "OS/2";};
            /\(.*QNX.*\)/ && do {return "Neutrino";};
            /\(.*VMS.*\)/ && do {return "OpenVMS";};
#            /\(.*Windows XP.*\)/ && do {return "Windows XP";};
#            /\(.*Windows NT 5\.1.*\)/ && do {return "Windows XP";};
            /\(.*Windows 2000.*\)/ && do {return "Windows 2000";};
            /Windows NT 5.*\)/ && do {return "Windows 2000";};
            /\(Windows.*NT/ && do {return "Windows NT";};
            /\(.*Win.*98.*4\.9.*\)/ && do {return "Windows ME";};
            /\(.*Win98.*\)/ && do {return "Windows 98";};
            /\(.*Win95.*\)/ && do {return "Windows 95";};
            /\(.*Win16.*\)/ && do {return "Windows 3.1";};
            /\(.*WinNT.*\)/ && do {return "Windows NT";};
            /\(.*32bit.*\)/ && do {return "Windows 95";};
            /\(.*16bit.*\)/ && do {return "Windows 3.1";};
            /\(.*Mac OS 9.*\)/ && do {return "Mac System 9.x";};
            /\(.*Mac OS 8\.6.*\)/ && do {return "Mac System 8.6";};
253 254 255 256 257 258 259 260 261 262 263
            /\(.*Mac OS 8\.5.*\)/ && do {return "Mac System 8.5";};
#we don't know 8.1
            /\(.*Mac OS 8\.1.*\)/ && do {return "Mac System 8.0";};
            /\(.*Mac OS 8\.0.*\)/ && do {return "Mac System 8.0";};
            /\(.*Mac OS 8[^.].*\)/ && do {return "Mac System 8.0";};
            /\(.*Mac OS 8.*\)/ && do {return "Mac System 8.6";};
            /\(.*Darwin.*\)/ && do {return "MacOS X";};
#silly
            /\(.*Mac.*PowerPC.*\)/ && do {return "Mac System 9.x";};
            /\(.*Mac.*PPC.*\)/ && do {return "Mac System 9.x";};
            /\(.*Mac.*68k.*\)/ && do {return "Mac System 8.0";};
264 265
#evil
            /Amiga/i && do {return "other";};
266 267 268
            /\(.*PowerPC.*\)/ && do {return "Mac System 9.x";};
            /\(.*PPC.*\)/ && do {return "Mac System 9.x";};
            /\(.*68K.*\)/ && do {return "Mac System 8.0";};
269
        }
terry%netscape.com's avatar
terry%netscape.com committed
270
    }
271 272
    # default
    return "other";
terry%netscape.com's avatar
terry%netscape.com committed
273 274 275
}


276
GetVersionTable();
terry%netscape.com's avatar
terry%netscape.com committed
277

278 279
my $assign_element = GeneratePersonInput('assigned_to', 1,
                                         formvalue('assigned_to'));
280
my $cc_element = GeneratePeopleInput('cc', formvalue('cc'));
terry%netscape.com's avatar
terry%netscape.com committed
281 282


283 284
my $priority = Param('defaultpriority');

285
my $priority_popup = make_popup('priority', \@::legal_priority,
286
                                formvalue('priority', $priority), 0);
287 288 289 290 291
my $sev_popup = make_popup('bug_severity', \@::legal_severity,
                           formvalue('bug_severity', 'normal'), 0);
my $platform_popup = make_popup('rep_platform', \@::legal_platform,
                                pickplatform(), 0);
my $opsys_popup = make_popup('op_sys', \@::legal_opsys, pickos(), 0);
terry%netscape.com's avatar
terry%netscape.com committed
292

293
if (0 == @{$::components{$product}}) {
294 295 296 297 298 299 300
        print "<H1>Permission Denied</H1>\n";
        print "Sorry.  You need to have at least one component for this product\n";
        print "in order to create a new bug.  Go to the \"Components\" link to create\n";
        print "a new component\n";
        print "<P>\n";
        PutFooter();
        exit;
301
} elsif (1 == @{$::components{$product}}) {
302 303 304 305
    # Only one component; just pick it.
    $::FORM{'component'} = $::components{$product}->[0];
}

306 307
my $component_popup = make_popup('component', $::components{$product},
                                 formvalue('component'), 1);
terry%netscape.com's avatar
terry%netscape.com committed
308

309
PutHeader ("Enter Bug","Enter Bug","This page lets you enter a new bug into Bugzilla.");
terry%netscape.com's avatar
terry%netscape.com committed
310

311 312 313
# Modified, -JMR, 2/24,00
# If the usebuggroupsentry parameter is set, we need to check and make sure
# that the user has permission to enter a bug against this product.
314 315 316 317 318 319 320 321 322 323 324
# Modified, -DDM, 3/11/00
# added GroupExists check so we don't choke on a groupless product
if(Param("usebuggroupsentry")
   && GroupExists($product)
   && !UserInGroup($product)) {
  print "<H1>Permission denied.</H1>\n";
  print "Sorry; you do not have the permissions necessary to enter\n";
  print "a bug against this product.\n";
  print "<P>\n";
  PutFooter();
  exit;
325 326 327 328 329 330 331 332 333 334 335 336
}

# Modified, -JMR, 2/18/00
# I'm putting in a select box in order to select whether to restrict this bug to
# the product's bug group or not, if the usebuggroups parameter is set, and if
# this product has a bug group.  This box will default to selected, but can be
# turned off if this bug should be world-viewable for some reason.
#
# To do this, I need to (1) get the bit and description for the bug group from
# the database, (2) insert the select box in the giant print statements below,
# and (3) update post_bug.cgi to process the additional input field.

337 338 339 340
# Modified, -DDM, 3/11/00
# Only need the bit here, and not the description.  Description is gotten
# when the select boxes for all the groups this user has access to are read
# in later on.
341 342 343
# First we get the bit and description for the group.
my $group_bit=0;
if(Param("usebuggroups") && GroupExists($product)) {
344
    SendSQL("select bit from groups ".
345 346
            "where name = ".SqlQuote($product)." ".
            "and isbuggroup != 0");
347
    ($group_bit) = FetchSQLData();
348 349
}

350
print "
351 352
<FORM METHOD=POST ACTION=\"post_bug.cgi\">
<INPUT TYPE=HIDDEN NAME=reporter VALUE=\"$::COOKIE{'Bugzilla_login'}\">
353
<INPUT TYPE=HIDDEN NAME=product VALUE=\""  . value_quote($product) . "\">
354 355 356 357 358 359 360 361 362 363 364 365 366 367
  <TABLE CELLSPACING=2 CELLPADDING=0 BORDER=0>";

if (Param("entryheaderhtml")){
  print "
  <TR>
    <td></td>
    <td colspan=3>" .
  Param("entryheaderhtml") . "\n" .
  " </td> 
  </TR>
  <TR><td><br></td></TR>";
}

print "
terry%netscape.com's avatar
terry%netscape.com committed
368
  <TR>
369 370
    <td ALIGN=right valign=top><B>Reporter:</B></td>
    <td valign=top>$::COOKIE{'Bugzilla_login'}</td>
terry%netscape.com's avatar
terry%netscape.com committed
371
    <td ALIGN=right valign=top><B>Product:</B></td>
372 373 374
    <td valign=top>$product</td>
  </TR>
  <TR>
terry%netscape.com's avatar
terry%netscape.com committed
375
    <td ALIGN=right valign=top><B>Version:</B></td>
376
    <td>" . Version_element(pickversion(), $product) . "</td>
377
    <td align=right valign=top><b><a href=\"describecomponents.cgi?product=" .
378
    url_quote($product) . "\">Component:</a></b></td>
terry%netscape.com's avatar
terry%netscape.com committed
379 380 381 382
    <td>$component_popup</td>
  </TR>
  <tr><td>&nbsp<td> <td> <td> <td> <td> </tr>
  <TR>
383
    <td align=right><B><A HREF=\"bug_status.html#rep_platform\">Platform:</A></B></td>
terry%netscape.com's avatar
terry%netscape.com committed
384
    <TD>$platform_popup</TD>
385
    <TD ALIGN=RIGHT><B><A HREF=\"bug_status.html#op_sys\">OS:</A></B></TD>
terry%netscape.com's avatar
terry%netscape.com committed
386 387 388 389 390
    <TD>$opsys_popup</TD>
    <td align=right valign=top></td>
    <td rowspan=3></td>
    <td></td>
  </TR>
391 392 393
  <TR>";
if (Param('letsubmitterchoosepriority')) {
    print "
394
    <TD ALIGN=RIGHT><B><A HREF=\"bug_status.html#priority\">Resolution<br>Priority</A>:</B></TD>
395 396 397 398 399 400
    <TD>$priority_popup</TD>";
} else {
    print '<INPUT TYPE=HIDDEN NAME=priority VALUE="' .
        value_quote($priority) . '">';
}
print "
401
    <TD ALIGN=RIGHT><B><A HREF=\"bug_status.html#severity\">Severity:</A></B></TD>
terry%netscape.com's avatar
terry%netscape.com committed
402 403 404 405 406
    <TD>$sev_popup</TD>
    <td></td>
    <td></td>
  </TR>
  <tr><td>&nbsp<td> <td> <td> <td> <td> </tr>
407 408
";

409
if (UserInGroup("editbugs") || UserInGroup("canconfirm")) {
410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426
    SendSQL("SELECT votestoconfirm FROM products WHERE product = " .
            SqlQuote($product));
    if (FetchOneColumn()) {
        print qq{
  <TR>
    <TD ALIGN="right"><B><A HREF="bug_status.html#status">Initial state:</B></A></TD>
    <TD COLSPAN="5">
};
        print BuildPulldown("bug_status",
                            [[$::unconfirmedstate], ["NEW"]],
                            "NEW");
        print "</TD></TR>";
    }
}


print "
terry%netscape.com's avatar
terry%netscape.com committed
427
  <tr>
428
    <TD ALIGN=RIGHT><B><A HREF=\"bug_status.html#assigned_to\">Assigned To:</A></B></TD>
terry%netscape.com's avatar
terry%netscape.com committed
429
    <TD colspan=5>$assign_element
430
    (Leave blank to assign to default component owner)</td>
terry%netscape.com's avatar
terry%netscape.com committed
431 432
  </tr>
  <tr>
433
    <TD ALIGN=RIGHT><B>Cc:</B></TD>
terry%netscape.com's avatar
terry%netscape.com committed
434 435 436 437 438 439
    <TD colspan=5>$cc_element</TD>
  </tr>
  <tr><td>&nbsp<td> <td> <td> <td> <td> </tr>
  <TR>
    <TD ALIGN=RIGHT><B>URL:</B>
    <TD COLSPAN=5>
440 441
      <INPUT NAME=bug_file_loc SIZE=60 value=\"" .
    ((formvalue('bug_file_loc') !~ /:/o) ? 'http://' : '') .
442 443
    value_quote(formvalue('bug_file_loc')) .
    "\"></TD>
terry%netscape.com's avatar
terry%netscape.com committed
444 445 446 447
  </TR>
  <TR>
    <TD ALIGN=RIGHT><B>Summary:</B>
    <TD COLSPAN=5>
448 449 450
      <INPUT NAME=short_desc SIZE=60 value=\"" .
    value_quote(formvalue('short_desc')) .
    "\"></TD>
terry%netscape.com's avatar
terry%netscape.com committed
451
  </TR>
452 453
  <tr><td align=right valign=top><B>Description:</b></td>
<!--  </tr> <tr> -->
454 455 456
    <td colspan=5><TEXTAREA WRAP=HARD NAME=comment ROWS=10 COLS=80>" .
    value_quote(formvalue('comment')) .
    "</TEXTAREA><BR></td>
457 458 459
  </tr>";

print "
460 461 462 463 464
  <tr>
   <td></td><td colspan=5>
";

if ($::usergroupset ne '0') {
465
    SendSQL("SELECT bit, name, description FROM groups " .
466
            "WHERE bit & $::usergroupset != 0 " .
467
            "  AND isbuggroup != 0 AND isactive = 1 ORDER BY description");
468 469
    # We only print out a header bit for this section if there are any
    # results.
470
    my $groupFound = 0;
471 472 473 474 475 476
    while (MoreSQLData()) {
        my ($bit, $prodname, $description) = (FetchSQLData());
        # Don't want to include product groups other than this product.
        unless(($prodname eq $product) || (!defined($::proddesc{$prodname}))) {
            next;
        }
477 478 479 480 481
        if(!$groupFound) {
          print "<br><b>Only users in the selected groups can view this bug:</b><br>\n";
          print "<font size=\"-1\">(Leave all boxes unchecked to make this a public bug.)</font><br><br>\n";
          $groupFound = 1;
        }
482 483 484 485 486 487 488 489
        # Rather than waste time with another Param check and another database
        # access, $group_bit will only have a non-zero value if we're using
        # bug groups and have  one for this product, so I'll check on that
        # instead here.  -JMR, 2/18/00
        # Moved this check to this location to fix conflict with existing
        # select-box patch.  Also, if $group_bit is 0, it won't match the
        # current group, either, so I'll compare it to the current bit
        # instead of checking for non-zero. -DDM, 3/11/00
490 491 492 493 494 495 496 497
        # Modifying this to use checkboxes instead of a select list.
        # -JMR, 5/11/01
        # If this is the group for this product, make it checked.
        my $check = ($group_bit == $bit);
        # If this is a bookmarked template, then we only want to set the bit
        # for those bits set in the template.
        if(formvalue("maketemplate","") eq "Remember values as bookmarkable template") {
          $check = formvalue("bit-$bit",0);
498
        }
499 500 501 502 503
        my $checked = $check ? " CHECKED" : "";
        # indent these a bit
        print "&nbsp;&nbsp;&nbsp;&nbsp;";
        print "<input type=checkbox name=\"bit-$bit\" value=1$checked>\n";
        print "$description<br>\n";
504 505 506 507 508 509
    }
}

print "
   </td>
  </tr>
terry%netscape.com's avatar
terry%netscape.com committed
510 511 512
  <tr>
    <td></td>
    <td colspan=5>
513
       <INPUT TYPE=\"submit\" VALUE=\"    Commit    \" ONCLICK=\"if (this.form.short_desc.value =='') { alert('Please enter a summary sentence for this bug.'); return false; }\">
terry%netscape.com's avatar
terry%netscape.com committed
514 515 516 517 518
       &nbsp;&nbsp;&nbsp;&nbsp;
       <INPUT TYPE=\"reset\" VALUE=\"Reset\">
       &nbsp;&nbsp;&nbsp;&nbsp;
       <INPUT TYPE=\"submit\" NAME=maketemplate VALUE=\"Remember values as bookmarkable template\">
    </td>
519 520 521 522 523 524 525 526 527 528 529 530 531 532 533
  </tr>";

if ( Param('usebrowserinfo') ) {
    print "
  <tr>
    <td></td>
    <td colspan=3>
     <br>
     Some fields initialized from your user-agent, 
     <b>$ENV{'HTTP_USER_AGENT'}</b>.  If you think it got it wrong, 
     please tell " . Param('maintainer') . " what it should have been.
    </td>
  </tr>";
}
print "
terry%netscape.com's avatar
terry%netscape.com committed
534 535
  </TABLE>
  <INPUT TYPE=hidden name=form_name VALUE=enter_bug>
536
</FORM>\n";
terry%netscape.com's avatar
terry%netscape.com committed
537

538 539
PutFooter();

540
print "</BODY></HTML>\n";
terry%netscape.com's avatar
terry%netscape.com committed
541