Loading ...
Sorry, an error occurred while loading the content.

BarCode Scanner to submit form

Expand Messages
  • Marcelo Estrela
    Here is the deal: When a page is loaded, it has to set a focus on an input type=text where I have to insert a number with 13 positions. After I have inserted
    Message 1 of 1 , Feb 5, 2004
    • 0 Attachment
      Here is the deal:

      When a page is loaded, it has to set a focus on an input type=text
      where I have to insert a number with 13 positions. After I have
      inserted the 13th digit the form should be submitted automatically.
      That's beacause I have a barcode scanner plugged on the keyboard entry
      and a PHP script has to monitor it.
      I have tried with no success this over Mozilla (and it has to work on
      every browser:
      function autoSubmit() {
      vr = document.form[codeBar].value;
      tam = vr.length;
      if (tam == 13){
      document.form.submit();
      }
      }';
      ...
      <input type="text" name="codeBar" size="13" maxlength="13"
      onBlur="autoSubmit()>

      anyone can help?
    Your message has been successfully submitted and would be delivered to recipients shortly.