How to run a JQuery function on page load MVC asp.net -


i have jquery function fetchfunctions() need run when page loaded. not sure how within mvc using template. don't have section on page. adding _layout page doesn't make sense.

inside of page add script tag

somepage.cshtml

<script>  window.onload = function(){   //script goes here  };  //or if prefer jquery  $(function(){   //script goes here  }); </script> 

Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -