2

I'm trying to change the default URL that Firefox has for Google. I don't want to change the search engine itself.

  • I tried changing keyword.url in about:config, but it doesn't work.
  • I tried the add on called Add to Search Bar, I can't manage to make it work either.

The URLs associated to the search engines have to be kept somewhere though — how can I change them?

1

2 Answers 2

2

Since Firefox uses the default search engine - the one currently selected in the search box drop down menu - in the right-click context menu you have to change the URL of the currently selected search engine. Firefox stores search engines the following way:

  1. Firefox installation directory\searchplugins (shipped search engines)
  2. Firefox profile folder\searchplugins (user-installed search engines)

Either way, if you want to change the URL of a search engine you have to edit the appropriate XML file, e. g. google.xml. If you need more help replacing the correct URL, have a look at Mozilla's Creating OpenSearch plugins for Firefox.

8
  • The folder /usr/lib/firefox/searchplugins exists, but is empty. I didn't install any search engines, so the 2. doesn't apply (there is no folder called searchplugins in my profile folder).
    – kbell
    Jul 27, 2012 at 7:31
  • You can take a look at restoring the default search engines at MozillaZine. If the button is enabled, clicking it should restore the default search engines. If the button isn't enabled, maybe the search engines are stored somewhere else.
    – JC2k8
    Jul 27, 2012 at 8:00
  • I have not installed or removed or made anything regarding to search engines. This is just firefox out of the box, given by ubuntu. Maybe there are some tweaks regarding ubuntu that are specific?
    – kbell
    Jul 27, 2012 at 8:12
  • I'm not on Linux, sorry. A quick google search seems to indicate that the search plugin may also reside here: /usr/lib/firefox-addons/searchplugins/en-US/google.xml.
    – JC2k8
    Jul 27, 2012 at 8:51
  • The folder /usr/lib/firefox-addons/searchplugins/ is empty too.
    – kbell
    Jul 27, 2012 at 9:18
2

The about:config value for the context menu search engine is browser.search.selectedEngine It's only a string like Google or Bing or... And the string used for this search is the one you have in keyword.url...

BTW: what is the value of keyword.url in your Firefox?

2
  • keyword.url is empty... but if I put something there, it doesn't change a thing. I don't have a browser.search.selectedEngine. All I have is a services.sync.prefs.sync.browser.search.selectedEngine, but it's not a string, it's a boolean.
    – kbell
    Jul 27, 2012 at 7:29
  • keyword.URL is only relevant when entering information in the location bar. Furthermore, keyword.enabled needs to be set to true for this to work.
    – JC2k8
    Jul 27, 2012 at 11:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.