搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

详细了解

full stop (period) key not working in certain text boxes (Firefox 42.0)

  • 7 个回答
  • 2 人有此问题
  • 13 次查看
  • 最后回复者为 dwl99

more options

I'm running Firefox 42.0 on a Windows 10 Pro PC. For some time now the full stop (period) key on the numbers keypad has stopped working in certain text boxes. It works fine in other text boxes (e.g. this one). It happens most commonly in text boxes relating to payments so if I type in 19.99 it appears as 1999. The full stop key in the main part of the keyboard works fine in any text box. I've tried 2 different keyboards and the same thing happens. And yes, I have numlock on. Anyone else had this?

I'm running Firefox 42.0 on a Windows 10 Pro PC. For some time now the full stop (period) key on the numbers keypad has stopped working in certain text boxes. It works fine in other text boxes (e.g. this one). It happens most commonly in text boxes relating to payments so if I type in 19.99 it appears as 1999. The full stop key in the main part of the keyboard works fine in any text box. I've tried 2 different keyboards and the same thing happens. And yes, I have numlock on. Anyone else had this?

所有回复 (7)

more options

Hmm, the numeric keypad sends different codes than the main part of the keyboard, but someone should have accounted for that.

Could you give a link to a form that has this problem and point out which field it is that won't accept that period?

more options

http://www.ebay.co.uk/sch/i.html?_from=R40&_trksid=m570.l1313&_nkw=tablet&_sacat=0 - on the far left, grey section of the page there is a section to select the price range. If I enter 2.99 in the box it shows as 299. The same page is fine in Edge browser.

more options

It works for me using a Microsoft keyboard and the U.S. English version of Firefox. The field has a feature I haven't used before:

<input class="price" pattern="\d*" size="6" maxlength="13" name="_udlo" id="e1-61" value="" type="text">

In theory, that should only allow digits (https://developer.mozilla.org/docs/We.../Constraint_validation#Validation-related_attributes) but it doesn't seem to be working on mine, I can type letters.

Needs a little further investigation.

由jscher2000 - Support Volunteer于修改

more options

Okay, upon further review, the "pattern" isn't enforced by Firefox as you type, it's a way for sites to validate input if they wish to do so. I'm not sure why the period on your numeric keypad isn't registering in that form but the regular period key is.

Could you try the box on the following test page to see what codes your keyboard is submitting for the regular period and the numeric keypad period:

http://dev.jeffersonscher.com/dom/keyevents2.html

This is what I'm getting:

(regular) keydown => 190 keypress => 46 keyup => 190

(numeric keypad) keydown => 110 keypress => 46 keyup => 110

more options

I got:

keydown => 190 keypress => 46 keyup => 190 keydown => 110 keypress => 46 keyup => 110

i.e. same as you

more options

Does it make a difference whether you use a '.' or a ',' in case the local language matters (en-GB)?

more options

It works if I enter ","