SitePoint Sponsor

User Tag List

Results 1 to 9 of 9

Thread: Text box beep

  1. #1
    SitePoint Member
    Join Date
    Oct 2010
    Posts
    4
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Post Text box beep

    Anyone have any idea how i can make the following textbox called rfidentry produce a beep noise upon a string of numbers being input into it?

    PHP Code:
    <%
    workorder Request.Form("workorder")
    %>
    <!
    DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <
    html>
    <
    head>
        <
    title############### </title>
        
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        
        <
    meta name="description" content=" add page description... "  />
        <
    meta name="keywords" content=" add keywords... " />
        

        <
    link href="_layout/style.css" rel="stylesheet" type="text/css" />
        
        <
    style type="text/css">
            
    #Text1
            
    {
                
    width234px;
                
    height26px;
            }
        </
    style>
        
        </
    head>
    <
    body onLoad="document.rfidentry.rfid.focus()">
        <
    div class="logo" onclick="document.location='default.asp';">
        </
    div>
        
        <
    div id="round_top"></div
        
        <
    div id="content" class="fixed">
          <
    div id="maincontent" class="fixed">

        
            <
    h2>Shop Floor Data System&nbsp;</h2>
                
            <
    h3 class="maincontent" style="margin-top:15%">Please swipe your <bold>A fob</boldat the reader.
            
            <
    form name="rfidentry" action="works_order.asp" method="POST">
            <
    input type="password" name="rfid" style="width: 321px; height: 26px"/>
            <
    input type="hidden" name="workorder" value="<%=workorder%>"/>
        
            </
    form>
            <
    br>
            <
    img class="img-center" src="_layout/images/rfid.gif" style="width: 210px; height: 210px"/>
            <
    br>
            </
    h3>

           
          </
    div>

        </
    div>
        
    </
    body>
    </
    html

  2. #2
    SitePoint Enthusiast
    Join Date
    Jan 2004
    Location
    Edinburgh, Scotland
    Posts
    90
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This _is_ possible, though maybe not practical.
    I can't recall what/where I read about it, but you would need to record your beep as an MP3 file (or whatever) which can be triggered with JavaScript. If you are lucky, and the volume is on/correct...
    I'll post again if I find a sensible reference.
    Throw away your Calculator -
    get instant results from www.calcResult.com

  3. #3
    SitePoint Wizard rguy84's Avatar
    Join Date
    Sep 2005
    Location
    Durham, NC
    Posts
    1,659
    Mentioned
    5 Post(s)
    Tagged
    0 Thread(s)
    Paul, I am guessing it will beep because of error. What will you do for deaf people or people at work w/o sound? Just a thought
    Ryan B | My Blog | Twitter

  4. #4
    SitePoint Member
    Join Date
    Oct 2010
    Posts
    4
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hey

    thanks for the replies. The system we have created is basically an interface for our ERP system. It is an electronic traveller system. Everyone employee has an RFID tag and this is how we are identifying who works on what job.

    It would be helpful for the people working on the shop floor if it simply beeped when they scanned there tag, this is because when you actually swipe your tag it is not always clear that it has swiped ok, i know it has and it works fine , however its just re assurance for the user more than anything.

    If it is too much of a faff we will probably just leave it, but it has turned out to be not as simple as we first thought

  5. #5
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,729
    Mentioned
    104 Post(s)
    Tagged
    4 Thread(s)
    If you want to start making use of some HTML5 features, you can access the audio API directly.

    Code javascript:
    var snd = new Audio("beep.mp3");
    snd.play();
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript

  6. #6
    SitePoint Member
    Join Date
    Oct 2010
    Posts
    4
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    so which browsers support HTML 5?

  7. #7
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,729
    Mentioned
    104 Post(s)
    Tagged
    4 Thread(s)
    Quote Originally Posted by paulmc87 View Post
    so which browsers support HTML 5?
    Most of them now. Here's a comparison of how different web browsers stack up.
    http://www.wikipedia.org/wiki/Compar...engines_(HTML5)
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript

  8. #8
    SitePoint Member
    Join Date
    Oct 2010
    Posts
    4
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    unfortuantely i can only use IE8

    i am thinking maybe flash may offer a solution

    i know nothing of javascript so will probably struggle unless i can find a complete solution

  9. #9
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,729
    Mentioned
    104 Post(s)
    Tagged
    4 Thread(s)
    There are other solutions, but you should test them out to ensure that they work as best as possible for you.

    Demonstration of Different Ways to Play a Sound from a Web Page
    http://www.phon.ucl.ac.uk/home/mark/audio/play.htm
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •