dcsimg
www.webdeveloper.com
Results 1 to 2 of 2

Thread: alert based on input value

  1. #1
    Join Date
    Sep 2006
    Posts
    18

    alert based on input value

    I know there has to be an easy solution for this one. When a text field receives an input value of 1,000 or higher - I need an alert to pop-up.

    Here's my code that is not working:
    function qtyFunction()
    {
    if(partform.qty.value>=1000){

    alert("Quantities 1,000+ are by special quote.");

    }
    }

    In the qty field I have onchange="qtyFunction(this.value);" (I also tried it without this.value in parentheses - no luck.

  2. #2
    Join Date
    Sep 2006
    Posts
    18
    Figured it out - needed to put the alert function before other functions onchange. Works fine now.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles