Closed Bug 524395 Opened 15 years ago Closed 15 years ago

Boolean charts And, Or, "add another chart" buttons do no work with JS turned off

Categories

(Bugzilla :: Query/Bug List, defect)

3.4.2
defect
Not set
normal

Tracking

()

RESOLVED FIXED
Bugzilla 3.4

People

(Reporter: guy.pyrzak, Assigned: LpSolit)

References

()

Details

(Keywords: regression)

Attachments

(1 file)

To reproduce
1. Turn off Javascript
2. Go to query.cgi advanced search
3. Try using the and, or or add another charts buttons on the boolean charts
4. Notice it submits the query instead of adding a chart.
I know what's going on. buglist.cgi is looking for &cmd- to decide if it should redirect the user to query.cgi (when JS is turned on, buglist.cgi is not called, as JS does the trick itself), but it can happen that cmd- is the first param in the URL, and so is not prepended by & but by ?. A more robust check is to loop over CGI params and redirect to query.cgi if it detects one param starting with cmd-.
I found what regressed this: bug 15809, which landed on the 3.4 branch. As it removes unused params, it now happens that cmd-add is the first param in the URL, and so is not prepended by & anymore.
Depends on: 15809
Flags: blocking3.4.3+
Keywords: regression
Target Milestone: --- → Bugzilla 3.4
Version: unspecified → 3.4.2
Yeah, just grep { $_ =~ /something/ } $cgi->param()
Attached patch patch, v1Splinter Review
I moved the check much higher in buglist.cgi, as first implemented in 2000 by Terry. We indeed don't want to do all the other stuff when all we want to do is to add another boolean chart.
Assignee: query-and-buglist → LpSolit
Status: NEW → ASSIGNED
Attachment #408296 - Flags: review?(mkanat)
Comment on attachment 408296 [details] [diff] [review]
patch, v1

Looks reasonable to me.
Attachment #408296 - Flags: review?(mkanat) → review+
Flags: approval3.4+
Flags: approval+
tip:

Checking in buglist.cgi;
/cvsroot/mozilla/webtools/bugzilla/buglist.cgi,v  <--  buglist.cgi
new revision: 1.405; previous revision: 1.404
done

3.4.2:

Checking in buglist.cgi;
/cvsroot/mozilla/webtools/bugzilla/buglist.cgi,v  <--  buglist.cgi
new revision: 1.394.2.6; previous revision: 1.394.2.5
done
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: