javascript - Handle Carriage Return from Barcode in Web Browser -


i writing web application needs take input barcode scanner.

currently, system printing barcode adding '\13' (i think carriage return) beginning of value. thus, whenever barcode scanned example firefox, cursor jumps search bar , puts value there rather in text field.

i cannot modify printed barcodes themselves. there way prevent barcode changing input field text box search bar?

thanks!

hitting enter not "jump" different input, instead submit formular in focus located. following keypresses go reloaded page, might end in autofocused search bar or so.

to prevent such, install keypress listener on barcode input field , call .preventdefault() on event when enter key. see prevent users submitting form hitting enter details.


Comments

Popular posts from this blog

database - VFP Grid + SQL server 2008 - grid not showing correctly -

jquery - Set jPicker field to empty value -

.htaccess - htaccess convert request to clean url and add slash at the end of the url -