jquery - How to load data as soon as welcome jsp gets loaded? -


i have index.jsp welcome page web application. now, hit url, need display table populated data coming backend services through ajax call. have mapped url using spring mvc , verified controller method getting hit.following jquery snippet,

 $(document).ready(function() {     var body = $("body");      $.ajax({         url : "${pagecontext.request.contextpath}/admin/product/display",          type : "get",          success : function(data) {             alert("alert");         }      }); }) 

i have observed alert not working. dont know going wrong here.


Comments

Popular posts from this blog

c++ - Function signature as a function template parameter -

algorithm - What are some ways to combine a number of (potentially incompatible) sorted sub-sets of a total set into a (partial) ordering of the total set? -

How to call a javascript function after the page loads with a chrome extension? -