Javascript question:   TypeError:  $(...).on is not a function

willsherwood used Ask the Experts™
I'm using the following script.  Can anyone help debug?     Thank you!


<script type="text/javascript" src=""></script>

<script type="text/javascript">

$(document).ready(function() {  // script wrapper

      $('textarea, input').on('blur', function() {
            var itemID = $(this).attr('id');
            var itemVal = $(this).val();
            var itemVal = itemVal.replace(/\n/g, '<br />');
            var itemVal = itemVal.replace(/&/g, 'and');
            var itemstring = "ID=" + itemID + "&value=" + itemVal;

      function processChange(itemstring){
            //return false;
                  type: "GET",
                  url: "php/update.php",
                  data: itemstring,
                  complete: function(data) {
                        var Resp = data.responseText;
                  success: function() {
                        $('#saved').css('display', 'block');
                        setTimeout(function() {
                                    opacity: 0,
                              }, 500, function(){
                                    $('#saved').css('display', 'none').css('opacity', '1');
                        }, 1000);
      }// end ProcessChange

}); // end script wrapper

Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Senior Software Developer
Your jQuery reference is for a very old version. Update your reference.

<script type="text/javascript" src=""></script>


thank you

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial