Once again... A barcode is simply a graphical representation of a string .... All barcode readers take this graphic SCAN and convert it into a String for the computer to understand... Most automatically input it into the computer as the string had been typed on the keyboard.. Additionally, most scanners come with the default set to append an ENTER or RETURN to the end of each barcode scanned. Therefore it is a simple process:
1) Create an Form <Input type=text name=barcode size=x>
2) use Javascript to ensure focus on your "barcode" field
3) when a user scans a barcode the form will automatically be submitted provided that the barcode scanner is appending a RETURN or ENTER key
I have done this many, mnay times and it works very well. The only thing to keep in mind is to use good QUALITY barcode scanners (which unfortunately tend to get expensive) I have found the scanners from symbol such as the LS2208 are very good.