Last Comment Bug 596439 - give searches from url bar a unique parameter to distinguish it from search bar
: give searches from url bar a unique parameter to distinguish it from search bar
Status: RESOLVED FIXED
:
Product: Firefox
Classification: Client Software
Component: General (show other bugs)
: Trunk
: All All
: -- normal (vote)
: ---
Assigned To: Matthew N. [:MattN]
:
Mentors:
: 624054 (view as bug list)
Depends on: 724116
Blocks:
  Show dependency treegraph
 
Reported: 2010-09-14 17:19 PDT by Alex Limi (:limi) — Firefox UX Team
Modified: 2013-11-13 02:19 PST (History)
11 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---
-


Attachments
patch (1.49 KB, patch)
2011-03-18 16:57 PDT, :Gavin Sharp [email: gavin@gavinsharp.com]
no flags Details | Diff | Splinter Review
updated patch (1.54 KB, patch)
2011-03-21 14:30 PDT, :Gavin Sharp [email: gavin@gavinsharp.com]
no flags Details | Diff | Splinter Review
patch with test fix (1.09 KB, patch)
2011-04-20 15:21 PDT, :Gavin Sharp [email: gavin@gavinsharp.com]
no flags Details | Diff | Splinter Review
real patch with test fix (2.68 KB, patch)
2011-04-20 15:22 PDT, :Gavin Sharp [email: gavin@gavinsharp.com]
dolske: review+
Details | Diff | Splinter Review

Description Alex Limi (:limi) — Firefox UX Team 2010-09-14 17:19:57 PDT
Filing this bug to ensure we have the means to track the searches from the following locations with separate codes:* Searches from the search bar* Searches from Firefox Start* Searches from the URL barI assume the search bar + FF Start already have separate codes, we need to make sure we can identify the searches from the URL bar with the recent changes in FF4.There might be a Google component here too (e.g. do we need to tell them about the new code?), but I'll leave that to the CCed parties to clarify.This probably also needs to block the final release of Firefox 4.
Comment 1 Alex Limi (:limi) — Firefox UX Team 2010-09-14 17:20:32 PDT
Requesting blocking for Firefox 4 final release.
Comment 2 Alex Limi (:limi) — Firefox UX Team 2010-09-14 17:21:34 PDT
For context on the URL bar searches, see bug 586821.
Comment 3 Kev Needham [:kev] 2010-09-14 18:06:36 PDT
Just to clarify, we're talking about Google channels only, correct?
Comment 4 Alex Limi (:limi) — Firefox UX Team 2010-09-14 19:45:30 PDT
Yes, I assume our Yandex volume isn't substantial enough yet to need this (and would likely result in similar distribution anyway)
Comment 5 :Gavin Sharp [email: gavin@gavinsharp.com] 2010-09-14 21:44:32 PDT
(In reply to comment #0)
> Filing this bug to ensure we have the means to track the searches from the
> following locations with separate codes

You mean "so that Google has the means to track them", right? We don't proxy searches through URLs that we control - they go directly to Google.

We use the same URL for keyword.URL and the search bar. We also use that URL for the search bar on about:home, but add the "&source=hp&channel=np" parameters to it (per bug 594675).
Comment 6 :Gavin Sharp [email: gavin@gavinsharp.com] 2010-09-14 21:47:38 PDT
Given keyword.URL a unique parameter would be doable, if desired (though we'd probably need to use a hacky approach similar to the one used for about:home...). Do you want to morph this bug to cover that?
Comment 7 Alex Limi (:limi) — Firefox UX Team 2010-09-15 00:08:36 PDT
(In reply to comment #5)
> You mean "so that Google has the means to track them", right? We don't proxy
> searches through URLs that we control - they go directly to Google.

Yes, whatever we add to the query string to separate Start page searches from search bar searches should also be added to the URL bar search. I have no idea how this is implemented, just wanted a bug on it, so it is tracked somewhere. :)
Comment 8 Kev Needham [:kev] 2010-09-15 11:02:40 PDT
Most likely the parameter will be "channel", but I'll need to coordinate with some folks here and at Google first. I think the same approach that we've looked at for the local home page applies, and adding the location bar searches should be the only other search surface that'd be affected.

Specifics to follow, but typically look to separate out queries form the home page, queries from the search bar, and queries from the location bar. The parameter will vary by provider, so it should be flexible. I'll update this bug with specifics when I have it.
Comment 9 :Gavin Sharp [email: gavin@gavinsharp.com] 2010-09-15 13:12:41 PDT
We already separate out about:home from search bar (see comment 5 / bug bug 594675).

Current state of affairs is this:
1) URL bar keyword search
  - Normal Google URL
2) Search bar search
  - Normal Google URL
3) about:home search field
  - Normal Google URL, plus "source=hp&channel=np"
4) Selected text context menu search
  - Normal Google URL

Adding a parameter for 1) is easy, just need to know what parameter to add (channel=kw?).

Adding a parameter for 4) would involve more work, so I'd like to avoid it. (It's likely a tiny number compared to the others...)
Comment 10 Alex Limi (:limi) — Firefox UX Team 2010-09-15 14:58:34 PDT
(In reply to comment #9)
> We already separate out about:home from search bar (see comment 5 / bug bug
> 594675).
> 
> Current state of affairs is this:
> 1) URL bar keyword search
>   - Normal Google URL
> 2) Search bar search
>   - Normal Google URL
> 3) about:home search field
>   - Normal Google URL, plus "source=hp&channel=np"
> 4) Selected text context menu search
>   - Normal Google URL
> 
> Adding a parameter for 1) is easy, just need to know what parameter to add
> (channel=kw?).

Works for me.

> Adding a parameter for 4) would involve more work, so I'd like to avoid it.
> (It's likely a tiny number compared to the others...)

Yeah, I wouldn't worry about that one for now.
Comment 11 Axel Hecht [pto-Aug-30][:Pike] 2010-09-16 13:24:21 PDT
Right now, the comments here lead me to believe that we're just talking about making google know where a search came from. I don't see us having anything that tells us, aka a feedback experiment, a search came from.
Comment 12 Mike Beltzner [:beltzner, not reading bugmail] 2010-09-20 15:33:03 PDT
Kev: you want to take this to Steve? I suspect they'll want to modify the channel= variable, as you say. They're using "np" for "new page"; perhaps "lb" for "location bar"? :)
Comment 13 Alex Limi (:limi) — Firefox UX Team 2010-11-10 11:44:41 PST
Not sure I understand why this is not blocking; having the ability to track how many of our users prefer the URL bar searches over the search box seems to be very important data to me, and is also important when considering the evolution and possible merge of search field & URL input fields in the future.

Re-requesting blocking.
Comment 14 Axel Hecht [pto-Aug-30][:Pike] 2010-11-10 11:58:53 PST
Limi, what you're asking for doesn't do what you expect it to, AFAICT.

With what folks are talking about in this bug, google will know how our folks use url bar searches, we will not. Is that your intention?

Also, http://mxr.mozilla.org/mozilla-central/source/browser/app/profile/firefox.js#219 sets keyword.URL to blank now.
Comment 15 :Gavin Sharp [email: gavin@gavinsharp.com] 2010-11-11 09:46:41 PST
keyword.URL isn't relevant, we can make location bar searches differentiable (to Google, not to us, as you point out) using the same technique we used for Yandex (x-moz-keywordsearch).
Comment 16 Dietrich Ayala (:dietrich) 2010-12-07 03:11:16 PST
Blocking- for comment #14 and #15. IIUC, this change doesn't do what Alex thinks it does, and outside of that, there's a better way to do it.
Comment 17 :Gavin Sharp [email: gavin@gavinsharp.com] 2011-01-08 13:00:10 PST
*** Bug 624054 has been marked as a duplicate of this bug. ***
Comment 18 Frank Yan (:fryn) 2011-01-08 19:32:16 PST
I explained to Limi how the code works, so he now has an understanding for why keyword.URL is irrelevant. Changed the bug title to reflect this.
Comment 19 Alex Limi (:limi) — Firefox UX Team 2011-01-09 02:07:31 PST
(In reply to comment #16)
> Blocking- for comment #14 and #15. IIUC, this change doesn't do what Alex
> thinks it does, and outside of that, there's a better way to do it.

I was asked by Jim to make sure we track this on the Google side. He can get the data on how search is initiated, and will — just because we currently don't do it, doesn't mean we don't want to. Happy to discuss it if you need more data, or more clarification.

Re-requesting blocking.
Comment 20 Alex Limi (:limi) — Firefox UX Team 2011-01-09 02:08:52 PST
And, carrying over information from bug 624054:

Ideally, searches from the Location Bar should have a source attribute, I
propose we add "&source=lb" for searches done here.
Comment 21 Kev Needham [:kev] 2011-01-09 06:06:53 PST
We'll need to confirm with Google on what an acceptable parameter would be, as they'll be pulling it. I believe they have a field for channels, but can't remember off-hand what it is. I'll talk to them tomorrow and put a patch in when I have it, but generally it can't be an arbitrary attribute.

While the current implementation of application/x-moz-keywordsearch is irrelevant in this use-case, I would like to see if we can't make it relevant for all other search surfaces in the future; it would help simplify search plugin integration/admin.
Comment 22 Frank Yan (:fryn) 2011-01-09 08:42:53 PST
(In reply to comment #20)
> And, carrying over information from bug 624054:
> 
> Ideally, searches from the Location Bar should have a source attribute, I
> propose we add "&source=lb" for searches done here.

(In reply to comment #21)
> We'll need to confirm with Google on what an acceptable parameter would be, as
> they'll be pulling it. I believe they have a field for channels, but can't
> remember off-hand what it is. I'll talk to them tomorrow and put a patch in
> when I have it, but generally it can't be an arbitrary attribute.

There is a parameter called "channel" that is used in some cases, but I don't know what it means. Setting the "source" parameter seems to make sense, because it's currently set to "hp" (short for home page) when searching from about:home.
Comment 23 Kev Needham [:kev] 2011-01-09 08:52:49 PST
Per above, it's something we shouldn't assume. 

Beltzner: could you confirm Google asked us to use "source" for the local start page? I'll use that as the lead-in with Google if so, and advise them of plans if we're all in agreement. 

> There is a parameter called "channel" that is used in some cases, but I don't
> know what it means. Setting the "source" parameter seems to make sense, because
> it's currently set to "hp" (short for home page) when searching from
> about:home.
Comment 24 Jim Cook (NEED INFO ONLY - Please flag) 2011-01-09 09:01:42 PST
Hey all...jumping in here late.  Sorry for the confusion by not being on here earlier.

Overarching Goal of this request
1)  Ensure we start getting reports from Google that separates Location Bar Searches (lb) from Startpage Searches vs Chrome Searches.  We get the latter 2 already on a monthly basis from Google in a critical report we analyze deeply.

2)  Without this separation of Location Bar vs Chrome, we will lose some critical data on our User Behavior for which we can build future great UI/product offerings

In reply to:
(comments 11 and 14:  Axel) - Yes, Google will know but they already know whether or not we do anything (they have enough statisical data on their own Chrome product feature).  By adding the attribute to FF4, we can force Google to report it back to us at Mozilla

(comment 13:  Limi) - I agree with this comment

(comments 15 & 16 - Gavin & Dietrich) - sounds like there might be a better way of doing it?  That's great.  Don't really care about the way as long as the requirement is met that Google starts adding this Location Bar Field to our Monthly Report they deliver to us.

(comment 21 - Kev) - Yes, we definitely need to communicate with Google to ensure they are aware of any change and can and will start reporting it back to us in a separate field
Comment 25 :Gavin Sharp [email: gavin@gavinsharp.com] 2011-01-09 12:35:14 PST
Bug 594675 is where we added the about:home parameter.

Not sure I understand the previous comments about x-moz-keywordsearch - we do want to use it for this, just like we did with Yandex:
http://hg.mozilla.org/l10n-central/ru/rev/07ae2c762256
Comment 26 Kev Needham [:kev] 2011-01-10 07:00:52 PST
(In reply to comment #25)
> Bug 594675 is where we added the about:home parameter.
> 
> Not sure I understand the previous comments about x-moz-keywordsearch - we do
> want to use it for this, just like we did with Yandex:
> http://hg.mozilla.org/l10n-central/ru/rev/07ae2c762256

my age-addled brain. I thought we had removed that bit. my bad.
Comment 27 Justin Dolske [:Dolske] 2011-01-11 18:22:02 PST
Unowned blocker, over to Frank.
Comment 28 Mike Beltzner [:beltzner, not reading bugmail] 2011-01-11 21:46:21 PST
I'm taking this off the blocker list. There's nothing stopping us from doing this after we ship Firefox 4, and a precursor step of working out the appropriate codes with Google still hasn't happened.
Comment 29 Frank Yan (:fryn) 2011-01-11 23:15:09 PST
Unassigning self, unless it becomes a blocker again or until we work out the appropriate codes with Google.
I'm happy to pick it up later though, if no one else is.
Comment 30 Alex Limi (:limi) — Firefox UX Team 2011-03-18 14:52:31 PDT
OK, finally got confirmation from Google on what to do here:

The query string for the location bar searches should be:

http://www.google.com/search?ie=UTF-8&oe=UTF-8&sourceid=navclient&client=google&channel=fflb&q=

Google representative said: "The only 2 new parameters being added to the existing setting are client=google and channel=fflb."
Comment 31 :Gavin Sharp [email: gavin@gavinsharp.com] 2011-03-18 16:57:24 PDT
Created attachment 520356 [details] [diff] [review]
patch

This adds the two extra parameters for URL-bar triggered searches.

With this patch, the URLs used for a query of "test 123" are:

Search bar (unchanged):
http://www.google.com/search?q=test+123&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a
URL bar (two added parameters):
http://www.google.com/search?q=test+123&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-a&client=google&channel=fflb
Comment 32 :Gavin Sharp [email: gavin@gavinsharp.com] 2011-03-21 14:25:34 PDT
There's a problem with comment 30 that I failed to notice earlier - we already send a "client" parameter, whose value is typically "firefox-a" (or "firefox" for builds where Google is not the default engine). I imagine we'll just want to continue sending that, and not add the additional client=google.
Comment 33 :Gavin Sharp [email: gavin@gavinsharp.com] 2011-03-21 14:30:27 PDT
Created attachment 520753 [details] [diff] [review]
updated patch
Comment 34 Kev Needham [:kev] 2011-03-21 16:08:36 PDT
Gavin: correct. client codes need to match what we're sending in the search bar.
Comment 35 Alex Limi (:limi) — Firefox UX Team 2011-03-24 10:34:21 PDT
I asked Kathy from Google, and she said:

> For tracking of the awesome bar, you will need to set the client=google (not firefox-a or firefox in this use case).  Please note that tracking will not work otherwise and all our previous testing was using this new keyword.URL setting, with client=google and channel=fflb.  This setting is only for searches coming from the awesome bar.

Kev, can you make sure we're doing the right thing here with Google?
Comment 36 Alex Limi (:limi) — Firefox UX Team 2011-03-24 10:35:01 PDT
Bleh, damn Bugzilla. Let's make that readable:

“For tracking of the awesome bar, you will need to set the client=google (not firefox-a or firefox in this use case).  Please note that tracking will not work otherwise and all our previous testing was using this new keyword.URL setting, with client=google and channel=fflb.  This setting is only for searches coming from the awesome bar.”
Comment 37 :Gavin Sharp [email: gavin@gavinsharp.com] 2011-03-29 14:31:06 PDT
That doesn't sound right - we still want these searches to be identified as coming from Firefox. Changing the value of the "client" parameter doesn't really make sense, assuming that's what it's used for.
Comment 38 :Gavin Sharp [email: gavin@gavinsharp.com] 2011-03-30 17:10:28 PDT
note to self: need to also update browser_keywordSearch.js
Comment 39 :Gavin Sharp [email: gavin@gavinsharp.com] 2011-04-20 15:21:38 PDT
Created attachment 527407 [details] [diff] [review]
patch with test fix

We still need to get confirmation about the parameters, but no matter what the details end up being, this is the approach we'll need. I still think a simple additional parameter is correct.
Comment 40 :Gavin Sharp [email: gavin@gavinsharp.com] 2011-04-20 15:22:58 PDT
Created attachment 527409 [details] [diff] [review]
real patch with test fix
Comment 41 Justin Dolske [:Dolske] 2011-05-13 16:40:42 PDT
Comment on attachment 527409 [details] [diff] [review]
real patch with test fix

r+ assuming you check with Google to confirm the arg is what they'll want.
Comment 42 Kev Needham [:kev] 2011-05-14 13:06:51 PDT
We're still in a holding pattern with Google, so please hold off landing this. Hope to have red light/green lighr next week, per Google reps.
Comment 43 :Gavin Sharp [email: gavin@gavinsharp.com] 2012-02-03 13:40:29 PST
Comment on attachment 527409 [details] [diff] [review]
real patch with test fix

This works for the moment, but I think we'd rather wait to fix bug 587780 and use that mechanism.
Comment 44 :Gavin Sharp [email: gavin@gavinsharp.com] 2012-03-01 11:58:32 PST
This was fixed by bug 724116. Bug 587780 will eventually make it a little more maintainable in general.

Note You need to log in before you can comment on or make changes to this bug.