Vyhľadajte odpoveď

Vyhnite sa podvodom s podporou. Nikdy vás nebudeme žiadať, aby ste zavolali alebo poslali SMS na telefónne číslo alebo zdieľali osobné informácie. Nahláste prosím podozrivú aktivitu použitím voľby “Nahlásiť zneužitie”.

Learn More

Copying number from url calculator

  • 1 odpoveď
  • 0 má tento problém
  • 5 zobrazení
  • Posledná odpoveď od cor-el

more options

When I use the url calculator, the number will display as expected, e.g. if I type 900-756.07 Firefox displays 143.93 in the url. However, when I try to copy that number, the length of the numbers decimal places changes substantially, e.g. 143.93 turns in 143.92999999999995.

Is there a way to prevent it changing the result?

When I use the url calculator, the number will display as expected, e.g. if I type 900-756.07 Firefox displays 143.93 in the url. However, when I try to copy that number, the length of the numbers decimal places changes substantially, e.g. 143.93 turns in 143.92999999999995. Is there a way to prevent it changing the result?

Všetky odpovede (1)

more options

That is how this seems to work with floats, you can get rounding errors, although it is odd that in the URL bar the result shows correct, but copy doesn't copy the rounded result. The Web Console behaves the same if I test this with .01 to .09, but shows the full result (only .01 gives .99)

You can possibly file an enhancement bug report under Firefox::Address Bar component to copy the rounded result that is displayed.

  • 1697251 - Add a calculator in the urlbar

Pomohla vám táto odpoveď?

Položiť otázku

Ak chcete odpovedať na príspevky, musíte sa prihlásiť do svojho účtu. Ak ešte nemáte účet, položte novú otázku.