News for hackers. Stuff that matters.
Re:Firefox Address Bar Tips by perihelions on Monday July 10, 2023 @09:57AM (#36666527)
The killer feature is that you can extend this with your own macros. E.g. if you want the address bar to recognize "hn " as a prefix keyword, and redirect "hn firefox address bar" to, say, Algolia — you simply create a bookmark with "Keyword": "hn" and "URL": "https://hn.algolia.com/?q=%s" (not actually a URL, don't click on it) – %s indicating where the macro parameter substitutes. Then "hn firefox address bar" macroexpands to

https://hn.algolia.com/?q=firefox%20address%20bar

Re:Firefox Address Bar Tips by velut on Monday July 10, 2023 @10:12AM (#36666737)
This is one of my favorite features that I use daily.

I use the URL "https://www.google.com/search?q=site:ycombinator.com+%s" to search content from HN, and "https://www.google.com/search?q=site:reddit.com+%s" to search on Reddit. I also have "https://www.npmjs.com/package/%s" to directly go to a package page on npm.

Re:Firefox Address Bar Tips by bmacho on Monday July 10, 2023 @10:21AM (#36666878)
Me too, on Microsoft Edge. Until one day an update nuked away all of my custom search keywords :(

This is probably less of a problem on firefox, where they are regular bookmarks.

Re:Firefox Address Bar Tips by ckosidows on Monday July 10, 2023 @11:14AM (#36667629)
Same happened to me recently. I lost my custom search keywords randomly one day
Re:Firefox Address Bar Tips by bmacho on Monday July 10, 2023 @11:33AM (#36667916)
Happened after a windows update for me. I've tried to restore them, inspect the database where they should be, but they were already gone. Maybe if you have a system backup, you can find yours!

I've found this random tutorial how to mass create Edge search engines by editing the Edge database https://jeffhandley.com/2022-10-17/custom-search-engines if you want to store your search engines in a separate file in the future

Re:Firefox Address Bar Tips by gnomespaceship on Monday July 10, 2023 @11:28AM (#36667844)
Btw if you also use DuckDuckGo, you can start your search with "!hn" and "!r" bangs: https://duckduckgo.com/bangs
Re:Firefox Address Bar Tips by ajot on Monday July 10, 2023 @11:35AM (#36667954)
And you can go full circle, adding DDG's bangs as bookmark keywords on Firefox!

https://www.ghacks.net/2022/01/13/use-all-of-duckduckgos-ban...

https://github.com/jameshealyio/bang-bookmarks/

Re:Firefox Address Bar Tips by ngshiheng on Tuesday July 11, 2023 @11:31PM (#36690165)
You can replicate DDG's bangs in Chrome too: https://jerrynsh.com/how-to-google-with-a-bang/#how-to-googl...
Re:Firefox Address Bar Tips by bmacho on Monday July 10, 2023 @10:27AM (#36666953)
Similarly you can run javascript programs on a site with a parameter from the url bar, if you want. For example you can make a bookmark with the URL

   javascript: document.body.innerHTML = "%s" + document.body.innerHTML
and add a keyword @addBefore and it will work. (Useless example, but it probably shows where and how the javascript runs.)
Re:Firefox Address Bar Tips by bshacklett on Monday July 10, 2023 @04:17PM (#36672352)
Now that’s awesome. Bookmarklets have felt largely useless to me since I got rid of the bookmarks bar outside of new tabs. This might make them useful again.
Re:Firefox Address Bar Tips by pjot on Monday July 10, 2023 @10:40AM (#36667147)
This is a feature in Chrome as well!

https://support.google.com/chrome/answer/95426

Re:Firefox Address Bar Tips by johnnyworker on Monday July 10, 2023 @10:21AM (#36666883)
Or just right-click the input field, and if the browser recognizes it as a search field (they're good at it by default, but you can implement https://github.com/dewitt/opensearch to make extra sure), you'll get an option to create a search from it, with a keyword of your choosing (haven't tried Safari).
Re:Firefox Address Bar Tips by raybb on Monday July 10, 2023 @11:15AM (#36667649)
I implemented it for OpenLibrary (https://github.com/internetarchive/openlibrary/pull/5104) and it was surprisingly easy and works well!
Re:Firefox Address Bar Tips by cubefox on Monday July 10, 2023 @11:17AM (#36667680)
At least at some point in the past, this method had the advantage of working also with POST searches, while the manual insertion of %s works only with GET.
Re:Firefox Address Bar Tips by bmacho on Monday July 10, 2023 @10:18AM (#36666835)
I've wrote the same, with the same algolia example :D

Do you remember if it was possible to edit or add custom search engines from GUI before? I remember having them, but I can't find it. Also it seems to me as a basic feature and not a "killer feature".

Re:Firefox Address Bar Tips by bejd on Monday July 10, 2023 @10:22AM (#36666896)
Right-click on a search box > "Add a Keyword for this Search".

Edit: it then gets saved as a bookmark and you can edit it like any other.

Re:Firefox Address Bar Tips by bmacho on Monday July 10, 2023 @10:25AM (#36666940)
I don't have that. Where? Algolia and google search boxes(? the input fields?) don't show anything like that.

edit: also if I modify a keyword for my opensearch/xml search engines in about:preferences#search , it won't show up as a regular bookmark. Also I can't even see the URL for those search engines.

Re:Firefox Address Bar Tips by velut on Monday July 10, 2023 @10:45AM (#36667245)
Right click inside a search box. There should be the option "Add a Keyword for this search".
Re:Firefox Address Bar Tips by bmacho on Monday July 10, 2023 @11:00AM (#36667447)
Where? What is a search box?
Re:Firefox Address Bar Tips by velut on Monday July 10, 2023 @11:11AM (#36667589)
The search input provided by a website. You can try with the one in the footer of Hacker News and it works. See https://imgur.com/oxqMw6D
Re:Firefox Address Bar Tips by TeMPOraL on Monday July 10, 2023 @02:52PM (#36671201)
There used to be a GUI for that. Then they removed it. The functionality is still sorta, kinda available, in varying and increasingly undiscoverable ways.

Last time I checked, you had to navigate to a search engine (and/or make a search with it?) and hope its author published some magic special microformat metadata that identifies it as a search engine - then Firefox would helpfully offer you an option to add it as a search engine, somewhere in the address bar. I don't remember if it had any indicator visible by default, or if you had to right-click the address bar first.

And now I learned they "improved" this once again - hiding the feature under a right-click on a search box.

It really seems like browser vendors want to soft-kill this options. I'm just not sure why, especially when it comes to Firefox.

Re:Firefox Address Bar Tips by zvmaz on Monday July 10, 2023 @03:10PM (#36671434)
There's a firefox plugin [1] that lets you add custom search engines; they will be visible in the settings menu under "Search Shortcuts" where you can set the keyword to trigger the custom search.

[1] https://addons.mozilla.org/en-US/firefox/addon/add-custom-se...

Re:Firefox Address Bar Tips by kevincox on Monday July 10, 2023 @10:23AM (#36666899)
Yup, I use this all the time. `d` is for searching my favourite D&D reference, `i` is for IMDB, `p` is for image search, `v` is for GIF search...

It is also great for keyword-based bookmarklets.

Re:Firefox Address Bar Tips by rascul on Monday July 10, 2023 @10:10AM (#36666714)
I use this often. I just wish there was a way to escape the keyword. Like for example if I wanted to do a web search for "hn firefox address bar" I have to click the correct search engine with my mouse. Maybe there's a method I'm not aware of.
Re:Firefox Address Bar Tips by velut on Monday July 10, 2023 @10:15AM (#36666784)
You can press Ctrl+K or type a `?` before the search query and Firefox will use your default search engine without expanding the bookmark macro.
Re:Firefox Address Bar Tips by rascul on Monday July 10, 2023 @10:23AM (#36666903)
I notice that ? is mentioned in the submitted article, but I didn't get what you said from it. Regardless, ? is apparently what I needed to solve my problem. Thanks!
Re:Firefox Address Bar Tips by notRobot on Monday July 10, 2023 @10:12AM (#36666746)
I think you can have the keywords begin with a # or a @ or a ! (a la DDG bangs).
Re:Firefox Address Bar Tips by usea on Monday July 10, 2023 @10:14AM (#36666773)
you can make another keyword search for your search engine, and use that instead of a naked search. like: "g hn firefox address bar"
Re:Firefox Address Bar Tips by atomlib on Monday July 10, 2023 @10:45AM (#36667244)
This is Firefox's best kept secret.

To this day I cannot fathom anyone willingly switching from Firefox to Chrome/Edge/any other Chromium-based browser. There are so many tiny features that are useful at least to myself, while a minor JavaScript performance advantage isn't something that important in the grand scale of things.

Re:Firefox Address Bar Tips by wartijn_ on Monday July 10, 2023 @10:54AM (#36667356)
You can do this in Chromium as well. So it might be Chromium's best kept secret too.
Re:Firefox Address Bar Tips by NikkiA on Monday July 10, 2023 @11:34AM (#36667930)
As far as I know, you can do it in all major browsers (probably not safari though)
Re:Firefox Address Bar Tips by sxg on Monday July 10, 2023 @11:37AM (#36667983)
You can do it in Raycast along with a lot of other shortcuts outside of web browsers. I actually like it better through Raycast because it acts as a universal search, app launcher, calculator, 1Password interface, etc. that's always available and not dependent on a browser.
Re:Firefox Address Bar Tips by pivo on Monday July 10, 2023 @12:16PM (#36668481)
There's a plugin that does this for Safari: https://apps.apple.com/app/keyword-search/id1558453954
Re:Firefox Address Bar Tips by ghostpepper on Monday July 10, 2023 @10:56AM (#36667380)
How does one search open tabs in Chrome?
Re:Firefox Address Bar Tips by WXLCKNO on Monday July 10, 2023 @11:05AM (#36667510)
Ctrl+shift+a or click that little arrow at the top right of the window and you can search there.

I also just saw this https://blog.google/products/chrome/search-your-tabs-bookmar...

I think I like the shorter Firefox version better but this is maybe easier to remember at first

Re:Firefox Address Bar Tips by mucle6 on Monday July 10, 2023 @11:36AM (#36667970)
I thought I was a power user....
Re:Firefox Address Bar Tips by zo1 on Monday July 10, 2023 @03:30PM (#36671729)
Non power users would use this more if the docs, marketing and promotion of it was prominent and talked about (or made to look "sexy" for lack of a better word). I think what we're seeing is that the "UX" folk have hijacked the conversation and made it so that it is the only expression of the capabilities an app has for user interaction.

I'm sitting here, recalling all my chats and meetings and workshops with UX folk, and not once can I recall the topic of keyboard shortcuts or tab sequence being brought up. It was all about color, branding, spacing, user flow, "journeys", "experience", conversion funnels, and all things visual.

Re:Firefox Address Bar Tips by pbhjpbhj on Monday July 10, 2023 @04:00PM (#36672141)
Ctrl+Shift+A works in Edge too, they don't have the caret as a search dialog handle though. TIL. Includes recently closed tabs too.
Re:Firefox Address Bar Tips by wartijn_ on Monday July 10, 2023 @11:03AM (#36667488)
By starting your search with "@tabs" You can change that behavior on in the settings
Re:Firefox Address Bar Tips by myfonj on Monday July 10, 2023 @12:10PM (#36668405)
Interestingly, in Microsoft Edge, entering `%` does the same as typing `@tabs <tab>`. And `^` as `@history`.
Re:Firefox Address Bar Tips by cubefox on Monday July 10, 2023 @11:03AM (#36667486)
I think he meant the custom website keyword search.
Re:Firefox Address Bar Tips by wartijn_ on Monday July 10, 2023 @11:07AM (#36667545)
I did mean that, but it is possible to search for tabs, history, or bookmarks by starting your search with an @. E.g. `@tabs ycombinator`
Re:Firefox Address Bar Tips by cpleppert on Monday July 10, 2023 @02:15PM (#36670621)
This bookmarklet will work:

  (function () { let sel = window.getSelection(); let Qr; if (sel && sel.toString().length > 0) {Qr=sel.toString()} else {Qr=prompt('Search Site for','');} let hna=window.location.hostname; if(Qr) {  location.href='http://www.google.com/search?&q=site:'+encodeURIComponent(hna)+'+'+escape(Qr)  }})();
You can attach to a keyboard shortcut with a launcher or applescript.
Re:Firefox Address Bar Tips by shscs911 on Monday July 10, 2023 @11:06AM (#36667535)
Ctrl+Shift+A
Re:Firefox Address Bar Tips by jabroni_salad on Monday July 10, 2023 @11:56AM (#36668230)
yep, just hit up 'manage search engines' and add a shortcut. I use this to navigate to servicenow documents when someone IMs me their number, one of my most used workflow helpers.

    https://<your servicenow base url>/text_search_exact_match.do?sysparm_search=%s
Re:Firefox Address Bar Tips by Neff on Monday July 10, 2023 @11:26AM (#36667811)
Funny enough, I just posted on Mastodon looking for recommendations of other browsers to try.

While I love the flexibility and openness that Firefox brings, there is a resource issue for me on my macbook pro. I have to spend a lot of time in Google Meets for work, and video conferencing via Firefox seems to redline the computer... It sounds like a jet engine and I wind up thermal throttling to the point that my machine becomes completely unresponsive.

I'd love to stay with Firefox - especially for the cross-device tab sharing and search - but the need for something stable is superseding my want to use a non-Google browser.

Re:Firefox Address Bar Tips by thesuitonym on Monday July 10, 2023 @12:17PM (#36668492)
I wonder if Google would have any vested interest in making Meets a bad experience in Firefox... No, it must be Firefox that's wrong!
Re:Firefox Address Bar Tips by Neff on Wednesday July 12, 2023 @11:12AM (#36695733)
I have no doubt that Google is hamstringing performance on Firefox. But that is far outside of my sphere of control so I am focusing on the things I can effect.

Another member recommended disabling hardware acceleration so that is the first thing I'll try. If you have any other recommendations on how I can reduce the impact of the issue I'd love to hear them.

Re:Firefox Address Bar Tips by paintballboi07 on Monday July 10, 2023 @01:22PM (#36669601)
Have you tried disabling hardware acceleration?
Re:Firefox Address Bar Tips by Neff on Wednesday July 12, 2023 @11:09AM (#36695689)
I haven't. That was recommended to me by someone else and something I am going to look into.

I would have assumed that offloading the video processing to the dedicated GPU would be a good thing, but hopefully that helps with the problem.

Re:Firefox Address Bar Tips by irae on Monday July 10, 2023 @02:38PM (#36671018)
* * *
Re:Firefox Address Bar Tips by matheusmoreira on Monday July 10, 2023 @11:48AM (#36668110)
Firefox is increasingly unfriendly to power users. Wouldn't surprise me if they got rid of this feature someday because they have statistics showing few people use it.
Re:Firefox Address Bar Tips by marcosdumay on Monday July 10, 2023 @12:24PM (#36668627)
Firefox is trending into the unfriendliness of Chrome and the other mainstream browsers.

That irritating and horrible; but until they follow that trend to conclusion, it's not a reason to switch at all.

Re:Firefox Address Bar Tips by HumblyTossed on Monday July 10, 2023 @12:35PM (#36668817)
Switching will accelerate this.
Re:Firefox Address Bar Tips by sbjs on Monday July 10, 2023 @01:16PM (#36669482)
And rightfully so. Why maintain a feature for a small minority? Let them fork and maintain it themselves.
Re:Firefox Address Bar Tips by WastingMyTime89 on Monday July 10, 2023 @01:41PM (#36669966)
The danger of this is obvious.

Everyone is there for a different minority used feature. By caring only about the feature used by the majority, you are actually satisfying no one.

That’s why product managers use persona on top of metrics. Nice products have niche features and some kind of personality. You don’t want to overfocus on them but stripping them all is a losing move.

Re:Firefox Address Bar Tips by IIsi50MHz on Tuesday July 11, 2023 @06:16PM (#36687994)
WordPerfect and Quattro Pro (now WordPerfect Suite, I think) seem to persist due catering to special needs of law firms. Catering to some niche users can keep you afloat despite an otherwise market-dominant competitor.
Re:Firefox Address Bar Tips by zo1 on Monday July 10, 2023 @01:52PM (#36670207)
"WTF" is there to maintain in the feature anyways? If it's such a bloated mess that this kind of small feature causes maintenance issues and a lot of effort to include in subsequent releases, then maybe it is time for Firefox to fail.

Sigh, I've been using Firefox for almost 2 decades, and this is the first I've heard of this feature.

Re:Firefox Address Bar Tips by mcpackieh on Monday July 10, 2023 @02:19PM (#36670700)
Firefox would have no users at all if Mozilla abandon us nerds and power users who all rely a slightly different set of Firefox's obscure features. If Mozilla were smart, they would embrace us instead of wishing we were more like normal users (if we were, we'd be using chrome already!)
Re:Firefox Address Bar Tips by ehnto on Monday July 10, 2023 @10:59PM (#36675922)
You risk driving away your evangelists for one.

If you only focus on the most popular features you eventually narrow your product to one feature, so obviously there is a balance in there somewhere between focus and utility as well. Identifying why people use your product is as important as knowing what they use. Chrome does all the things I actually use from Firefox, but I use Firefox because when I ever need slightly more hackability it is there for me. That is at best, a once a year occurance.

Re:Firefox Address Bar Tips by chaxor on Monday July 10, 2023 @09:58PM (#36675585)
Power users are firefox's main demographic.

I see this so much so, it's to the point that If I see you're using something else, I assume you're not a developer, and you're likely not a power user.

Re:Firefox Address Bar Tips by chii on Tuesday July 11, 2023 @06:08AM (#36678776)
i do feel chrome devtools is just edges out firefox's
Re:Firefox Address Bar Tips by baby on Monday July 10, 2023 @11:52AM (#36668172)
And then there’s tree style tabs. But actually I moved to Chrome due to how many issues I ran into with tree style tabs due to firefox not letting do its thing
Re:Firefox Address Bar Tips by kenmacd on Monday July 10, 2023 @12:15PM (#36668478)
Well, in case you decide to move back, give Sidebery a try. I switched a while back haven't had any issues.
Re:Firefox Address Bar Tips by Zecc on Tuesday July 11, 2023 @04:08AM (#36677873)
I second this. I've had the very rare message saying the tab tree has gotten out of sync (always as a consequence of me moving tabs between incognito windows), but the first time it happened clicking the message refreshed the tab tree successfully; the second time it didn't but toggling the sidebar off and on fixed it. I've had no problems with stability.

And to me the context menu option to unload tabs is a killer feature.

Re:Firefox Address Bar Tips by eitland on Monday July 10, 2023 @02:51PM (#36671191)
So, if I understood you correct, you had issues with TST and instead of disabling TST, you went for Chrome?
Re:Firefox Address Bar Tips by fn-mote on Monday July 10, 2023 @03:07PM (#36671397)
They want a good tab manager... so they changed because the one they tried for Firefox did not work.
Re:Firefox Address Bar Tips by eitland on Monday July 10, 2023 @03:39PM (#36671847)
Over to Chrome that - as far as I have found - is worse off than Firefox in all possible ways when it comes to tab management?

Have I missed something?

Re:Firefox Address Bar Tips by baby on Monday July 10, 2023 @11:55PM (#36676245)
It became slow and the only reason that was keeping me in Firefox (TST) started getting more and more broken so I switched. I used to be so vocal about TST back in the days that I’m probably the reason you use it btw.
Re:Firefox Address Bar Tips by eitland on Tuesday July 11, 2023 @02:19AM (#36677060)
I see.

I still manage to use TST, but part of my reason for using Firefox is just because I don't want to use anything Chromium based.

Oh, and also I don't really want to support Mozilla either so I am experimenting with LibreWolf as my secondary browser and so far it has been great.

Re:Firefox Address Bar Tips by sucralose on Monday July 10, 2023 @11:54AM (#36668215)
Custom bookmark / search engine functionality is easy to replicate on Linux with a few shell scripts, though.

I use Brave and yet use some complex search engines such as making POST requests to APIs based on the search input and telling the browser to open a URL provided in the API's HTTP response.

Re:Firefox Address Bar Tips by drozycki on Monday July 10, 2023 @12:38PM (#36668857)
Chrome would auto install site specific search in its initial beta release in September 2008. The ability to set your own keywords came soon after. https://lifehacker.com/enable-chromes-best-features-in-firef...
Re:Firefox Address Bar Tips by pbreit on Monday July 10, 2023 @01:18PM (#36669520)
Chrome manages to do this without a command character. Much better UX.
Re:Firefox Address Bar Tips by tzot on Monday July 10, 2023 @02:23PM (#36670767)
Firefox without a command character searches everywhere; you use a command character to restrict your search to a specific category (history, bookmarks, open tabs etc).

Assumably Chromes does the same (ie without some prefix searches everywhere, with some prefix —or keypress— searches in a specific category). If Chrome doesn't do that, then Firefox's is the much better UX, otherwise they're equivalent.

Re:Firefox Address Bar Tips by IceSentry on Monday July 10, 2023 @01:51PM (#36670181)
I use vivaldi because of the tab stack feature and until firefox gets support for something close to it I just can't switch. I tried to browse the web without it but I always come back to vivaldi. I have a tab hoarding problem and it's the only browser that actually makes helps me manage it.
Re:Firefox Address Bar Tips by aldanor on Monday July 10, 2023 @03:18PM (#36671542)
I use Firefox mainly because of TreeStyleTab which lets me have 1k-2k tabs with no problem. Beats all other vertical tab options I've seen so far in other browsers
Re:Firefox Address Bar Tips by asadotzler on Monday July 10, 2023 @02:59PM (#36671294)
I've been trying to tell people about this for over two decades, literally, https://www-archive.mozilla.org/docs/end-user/keywords.html
Re:Firefox Address Bar Tips by pbhjpbhj on Monday July 10, 2023 @03:55PM (#36672083)
Not really, Chrome-based browsers have search keywords too.

What I would like most on the Chrome-based browser I have to use at work is history (^ keywords) and bookmark searching (# tag keywords, or * bookmark keywords) using "awesomebar" operators that Firefox has.

I'd really really like it if a form of search keywords could be used for forms that don't work as GET requests.

Re:Firefox Address Bar Tips by nine_k on Monday July 10, 2023 @04:08PM (#36672230)
Another great thing that only seem to exist for Firefox is Tree Style Tab [1] and a bunch of plugins around it. It completely changes the way I browse.

There is an honest but much, much more limited attempt top bring a something similar to Chromium: [2].

[1]: https://addons.mozilla.org/en-US/firefox/addon/tree-style-ta...

[2]: https://chrome.google.com/webstore/detail/tree-style-tab/oic...

Re:Firefox Address Bar Tips by MetallicCloud on Monday July 10, 2023 @04:23PM (#36672418)
Is there a good way to hide the top tabs without getting into barely supported config files?

I like TST, but I gave up on it because I could never get the top tabs hidden correctly, and all the information I could find on the internet was different levels of out of date.

Re:Firefox Address Bar Tips by velut on Monday July 10, 2023 @04:59PM (#36672880)
I don't think so. I use Sidebery and their recommended approach is to edit userChrome.css. It's not too bad and works well. See https://github.com/mbnuqw/sidebery/wiki/Firefox-Styles-Snipp....
Re:Firefox Address Bar Tips by wlesieutre on Monday July 10, 2023 @05:18PM (#36673093)
I see a sibling comment posted a link to some tab bar hiding CSS, but having gone though the same "different levels of out of date" problem myself I'll add my own solution that I'm currently using in Firefox 114 on Windows 11. Not perfectly space efficient, but avoids some issues with totally hiding the window titlebar, since I still wanted to keep the minimize/maximize/close controls up there.

Some of this may be platform specific to Windows (can't speak to window management buttons on other platforms), but hopefully it helps if anyone in this thread needs it or lands here later from search results:

  /*  Hide the tabs within TabsToolbar*/
  .toolbar-items {
      display: none;
  }
  
  /* Make the min/max/close buttons align to the right*/
  #TabsToolbar {
      display: flex;
      flex-direction: row-reverse;
  }
  
  /*  Hide the titlebar spacers, which push the buttons away from the corner */
  .titlebar-spacer {
      display: none;
  }
  
  /* Hide the sidebar header */
  #sidebar-header {
      display: none;
  }
Stupid that this sort of fiddling is required when other browsers (like Edge and Brave) are doing native sidebar tabs, but I do like how compact Firefox's can be, plus being a tree instead of a flat list.

Enabling userChrome.css files and finding where to put it is left as an exercise to the reader.

Re:Firefox Address Bar Tips by nine_k on Monday July 10, 2023 @05:26PM (#36673200)
Indeed. Works for me, but I'd love it to be an about:config setting for power users, or maybe even a View menu item.
Re:Firefox Address Bar Tips by nine_k on Monday July 10, 2023 @05:27PM (#36673212)
Finding the profile directory is as easy as opening about:support (also available via the Help menu).
Re:Firefox Address Bar Tips by wlesieutre on Monday July 10, 2023 @05:32PM (#36673263)
IIRC there's also a config flag you need to set, otherwise it won't load the userchrome file. I forget the details, it's been a while since I set this up.
Re:Firefox Address Bar Tips by AlecSchueler on Monday July 10, 2023 @05:02PM (#36672907)
This thread really makes me miss old vimperator/pentadactyl.,
Re:Firefox Address Bar Tips by Dalewyn on Monday July 10, 2023 @04:29PM (#36672501)
>a minor JavaScript performance advantage

Consider just how many layers of JavaShit webdevs want to slap down on their websites these days, that "minor" performance difference adds up. Death by a thousand cuts, basically.

Re:Firefox Address Bar Tips by porridgeraisin on Wednesday July 12, 2023 @12:26AM (#36690472)
This is there in chromium based browsers too, though. Settings -> search engine -> site search and then the exact same mechanism.
Re:Firefox Address Bar Tips by a_c on Monday July 10, 2023 @11:00AM (#36667440)
I have been using duckduckgo's bang feature for searching a particular site. e.g. !hn to search on here, !w on wiki and !g back to google is the result from ddg looks off.
Re:Firefox Address Bar Tips by naturalpb on Monday July 10, 2023 @12:02PM (#36668309)
I love DDG's bangs. If I want to see Google results, I use !s for Startpage instead. It's Google results through Startpage's search proxy.
Re:Firefox Address Bar Tips by yannyu on Monday July 10, 2023 @11:13AM (#36667610)
It's funny that this used to be a killer feature in Opera before they fell off. Between that and mouse gestures, they were really ahead of their time.
Re:Firefox Address Bar Tips by ugh123 on Monday July 10, 2023 @12:00PM (#36668281)
This is also available in Chrome!
Re:Firefox Address Bar Tips by dugmartin on Monday July 10, 2023 @12:07PM (#36668354)
This used to be baked into Chrome too but they removed it. I'm guessing to juice the Google search metrics.

https://twitter.com/googlechrome/status/1504858912692084745

Re:Firefox Address Bar Tips by Ajedi32 on Monday July 10, 2023 @12:26PM (#36668664)
The Tweet says it's still there, just slightly more buried than it used to be. Which is a shame since it's one of the most useful features in Chrome and not a lot of people know about it.

Still way less confusing than Firefox's UI for this though. What I like most about Chrome's implementation is how by default the search engine is linked to the main site, so I can type "yo<enter>" to visit the YouTube homepage or "yo<tab>" to search YouTube. And there's no need to manually set anything up (except to click the "activate" button now next to each site you want to the feature on, unfortunately).

Re:Firefox Address Bar Tips by gregsadetsky on Monday July 10, 2023 @12:12PM (#36668422)
The same is available in Chrome. I made a list of shortcuts I use here [0] -- copying a few favorites below:

   shortcut: "aw", lets you type: "aw s3", "aw iam", etc.
   https://console.aws.amazon.com/%s

   shortcut: "amzn", searches the retail side
   https://www.amazon.com/s/?field-keywords=%s

   shortcut: "gm", searches through gmail (change the 0 if you use multiple accounts)
   https://mail.google.com/mail/u/0/#search/%s

   shortcut: "maps", searches google maps
   https://www.google.com/maps/search/%s/

   shortcut: "img", searches google images
   https://www.google.com/search?tbm=isch&q=%s

   shortcut: "wp", goes directly to the article if it exists
   https://en.wikipedia.org/wiki/%s

   shortcut: "yt", searches youtube
   https://www.youtube.com/results?search_query=%s
[0] https://github.com/gregsadetsky/custom-search-engines
Re:Firefox Address Bar Tips by cpleppert on Monday July 10, 2023 @02:20PM (#36670728)
You can also use a duckduckgo query like ! site:site.com query. That is more reliable when using something like wikipedia when you aren't sure of the exact title and don't have to type it all out.
Re:Firefox Address Bar Tips by Zecc on Tuesday July 11, 2023 @03:58AM (#36677807)
Of course for Wikipedia specifically you'd use `!wiki query` instead.
Re:Firefox Address Bar Tips by robbyking on Monday July 10, 2023 @02:56PM (#36671264)
And IIRC, Chrome copied this from Opera. It's a shame Opera never found its audience (or more specifically, a revenue stream), they pioneered a lot of browser features that we consider to be standard these days, like tabs and support for extensions.
Re:Firefox Address Bar Tips by kbenson on Monday July 10, 2023 @06:41PM (#36674005)
It's been around in some form in most major browsers for decades. I remember Creating custom search entries in Firefox (or was it Phoenix still at that point?) in the early 2000's.
Re:Firefox Address Bar Tips by tomphoolery on Monday July 10, 2023 @06:55PM (#36674136)
is it really a "shame"? opera is the oldest successful browser of all time.
Re:Firefox Address Bar Tips by jessriedel on Monday July 10, 2023 @03:22PM (#36671601)
My list:

Aliexpress alternativeto.net Amazon Apple AppStore ArXiv Bing Video BookFinder ISBN DHL Tracking Number DOI Resolver duckduckgo.com ebay.com Facebook HackerNews (Angolia search) ISBN Search Library Genesis MathOverflow Physics.StackExchange Scholarpedia Sci-Hub (DOI) SciRate (arXiv) Scite.ai Dictionary.com Thesaurus.com Tripadvisor.com Twitter Urban Dictionary Walmart Wayback Machine Wikipedia Wolfram Alpha Weather Underground Yelp YouTube Video Search images.google.com scholar.google.com maps.google.com news.google.com scholar.google.com video.google.com

I have about half of these memorized enough to use regularly.

Re:Firefox Address Bar Tips by momothereal on Monday July 10, 2023 @05:51PM (#36673445)
My company intranet has a shortcut/URN website that we all configure as "go", so "go home", "go paystubs", etc. Anyone can create URNs. No more stale bookmarks when the HR system keeps changing. Very useful!
Re:Firefox Address Bar Tips by anilit99 on Monday July 10, 2023 @06:14PM (#36673743)
Chase?
Re:Firefox Address Bar Tips by momothereal on Monday July 10, 2023 @06:44PM (#36674028)
No but I'm sure many big orgs to this! Much easier than updating a home page with 1000+ links
Re:Firefox Address Bar Tips by Jenk on Monday July 10, 2023 @07:04PM (#36674214)
My big-org can barely do DNS let alone something as fancy as an intranet search that works/is useable!
Re:Firefox Address Bar Tips by hipjiveguy on Monday July 10, 2023 @09:42PM (#36675481)
Chrome broke this recently, for shortcuts that have no substitution. The ominibox history takes over.

For example, I used to be able to just type, "yt" and go to youtube, but now Ominbox history replaces it with my most recent history item that has "yt" in it

shortcut: "yt", goes to youtube https://www.youtube.com/

Re:Firefox Address Bar Tips by FalconSensei on Monday July 10, 2023 @12:14PM (#36668468)
this is just the search engines feature on chrome...
Re:Firefox Address Bar Tips by girishso on Monday July 10, 2023 @12:23PM (#36668612)
I don't see any "Keyword" field when creating bookmark, only "Tags".
Re:Firefox Address Bar Tips by vanderZwan on Monday July 10, 2023 @01:20PM (#36669553)
If you mean from clicking on the star in the address bar, that is correct.

However, if you edit the bookmark afterwards from the bookmarks sidebar, or add a bookmark on the "Manage bookmarks" tab (CTRL+SHIFT+O), you do see it.

Re:Firefox Address Bar Tips by girishso on Monday July 10, 2023 @01:34PM (#36669811)
Yes, that did help, Thanks!
Re:Firefox Address Bar Tips by brianpan on Monday July 10, 2023 @01:32PM (#36669767)
It's kind of weird that these turn into bookmarks and are mixed in with your bookmarks.

I think what people are talking about in this thread are "Search Shortcuts". And I don't know why this is a "best kept secret"; it's right in the Search section of your FF settings.

If you want to create one "one the fly", don't create a bookmark, but instead right-click in a search field and choose "Add a keyword for this search..." You can try it using the search at the bottom of this page.

Re:Firefox Address Bar Tips by mcpackieh on Monday July 10, 2023 @02:23PM (#36670766)
The easiest way is to right-click on a search field and select "Add a Keyword for this Search"
Re:Firefox Address Bar Tips by jimmaswell on Monday July 10, 2023 @12:33PM (#36668772)
Mobile used to have this too until they ruined it. And now they won't add it back with no valid justification.
Re:Firefox Address Bar Tips by behnamoh on Monday July 10, 2023 @12:51PM (#36669075)
Re:Firefox Address Bar Tips by ris58h on Monday July 10, 2023 @01:49PM (#36670149)
Use it daily for GitHub code search (gh - https://github.com/search?type=code&q=%s).
Re:Firefox Address Bar Tips by unsungNovelty on Monday July 10, 2023 @01:51PM (#36670190)
There is Duckduckgo Bangs - https://duckduckgo.com/bangs. They directly searches inside a website. There are a total of 13,563 bangs of websites. Twitter, Amazon, Stackoverflow, wikipedia, arch linux. You have to set your search engine to DDG though.

Wanna check if Thunderbird v115 is in arch repos? Ctrl + L, !archpkg thunderbird

Boom!

My favourites:

!w <term> searches <term> inside Wikipedia

!so <term> searches for that term inside stackoverflow

!a <term> searches inside amazon.com

!ai <term> searches inside amazon.in

!arch <term> searches inside arch wiki article for that term

!archpkg <term> directly searches for archlinux.org/packages

Also, I just learned that there is a "!hackernews"

Re:Firefox Address Bar Tips by jcul on Monday July 10, 2023 @02:45PM (#36671099)
And they are also supported by kagi.

It's nice that kagi lets you define your own, so I can have custom ones across browsers / mobile / desktop... So long as I'm logged in and have configured kagi to be my default search engine (my phone defaults to ddg and sometimes I might use a browser in a VM or something).

Re:Firefox Address Bar Tips by Antipode on Monday July 10, 2023 @03:10PM (#36671430)
!hn is also for hacker news
Re:Firefox Address Bar Tips by mcpackieh on Monday July 10, 2023 @02:06PM (#36670453)
With these search keywords, I've cut down on my general purpose search engine use dramatically, maybe 90%. Most of my searches through ddg/google used to be searches I intended to land on a known website with, so with search keywords for the search functionality on wikipedia, documentation websites, etc, I have been able to cut out the middleman.

Also, people slag on wikipedia's search functionality a lot, but I've found it to actually be pretty good even with imprecise searches. For instance, I forgot the name of Lubyanka, but searching for "KGB prison" found it: https://en.wikipedia.org/w/index.php?search=kgb%20prison

Re:Firefox Address Bar Tips by bombolo on Monday July 10, 2023 @02:50PM (#36671174)
This has been available on kde for several years.
Re:Firefox Address Bar Tips by asadotzler on Monday July 10, 2023 @02:58PM (#36671283)
I wrote all about this kind of thing back in 2001 or so

https://www-archive.mozilla.org/docs/end-user/keywords.html

Re:Firefox Address Bar Tips by viewtransform on Monday July 10, 2023 @03:16PM (#36671506)
Often times during a Teams meeting someone would wonder who had filed this ticket and I would "Control-L p Jose Smith" to instantly bring up the org chart for Jose Smith. People were amazed.

The Control-L/Command-L(mac) to focus the url bar. p is the keyword set to search the internal company org chart.

Another useful Firefox feature is to right click, Take Screenshot, and save the full web page rendered as you see it as an image. This is useful for those internal webpages with tables and fancy javascript rendered widgets that never properly render to pdf when saving the page.

Re:Firefox Address Bar Tips by yasenn on Monday July 10, 2023 @04:05PM (#36672196)
Is there some mobile browser with the same macro feature for address bar?

https://hn.algolia.com/?q=firefox%20address%20bar

Re:Firefox Address Bar Tips by 1vuio0pswjnm7 on Monday July 10, 2023 @05:14PM (#36673046)
This is a very old feature that (IIRC) all browsers copied that dates back to at least Microsoft Internet Explorer. I also recall people marketed it as a gimmick and came up with some silly names for it, e.g., "shortcuts". (I will try to find the originating browser and date it was introduced unless someone here beats me to it.)

Even today, Chrome presumptuously calls this macro expansion "site search".

I use it to access static pages. For example, I have local httpd's serving local pages on localhost addresses. One is a "clipboard" that I use in Chromebook "Guest" mode to output text from Chrome to a file descriptor, e.g., stdout or a file under /usr/local. This enables me to use UNIX utilities to process text from Chrome. (Chromebooks attempt to limit Chrome user access to the filesystem to a folder that the user can only access by using Chrome.)

For example, given the macro "https://127.0.0.8/%s.html", when I type "clip" in the address bar, the browser navigates to a local page

   https://127.0.0.8/clip.html
This page is an HTML form with a textarea where I can paste text that I want to output to a file descriptor, e.g., stdout or a file under /usr/local.

Another example is a static page that is a list of web search results from various search engines. These results pages are generated by a command line web search system I created using only standard UNIX utilities.

A final example is that I use "site search" to quickly navigate to chrome://settings pages with a single key, e.g., chrome://settings/clearBrowserData, chrome://settings/siteData, chrome://settings/content/all, or chrome://settings/searchEngines.

1. I find this label comical as I'm not a "developer". I'm just a computer user trying to work around problems caused by ad-supported "tech" companies in the comparitively rare instances I have to use one of their graphical web browsers.

Re:Firefox Address Bar Tips by conaclos on Monday July 10, 2023 @05:57PM (#36673520)
I really like keywords. I use keywords for search engines and bookmarks. I created several ones to mirror DuckDuckGo bangs.

It is unfortunate that add-ons cannot add a set of keywords: it would be great to have all DuckDuckGo bangs defined as keywords by an add-on.

Re:Firefox Address Bar Tips by Max_Mustermann on Monday July 10, 2023 @07:35PM (#36674536)
This was sadly deprecated on Android: https://github.com/mozilla-mobile/fenix/issues/12099

It was such a huge loss for me that for at least a year I used the outdated pre-Fenix. Now they still work on Desktop but they just stopped working on Android (althouth the bookmarks itself are synced-up)

Re:Firefox Address Bar Tips by TRiG_Ireland on Tuesday July 11, 2023 @07:52AM (#36679688)
Yup. I use d to search Onelook Dictionary.
Re:Firefox Address Bar Tips by conor- on Wednesday July 12, 2023 @12:21PM (#36696988)
DDG bangs[0] does this too but without the need to set up your own custom macros.

[0] https://duckduckgo.com/bangs

Re:Firefox Address Bar Tips by doe88 on Saturday July 15, 2023 @10:00AM (#36736830)