I am creating jQuerymobile website. I have a tag like this in page1.html
<a href="Page2.html">go to page 2</a>
If I click on it will go Page2.html. After the page is loaded I need to call a js function .
I tried 2 ways to put the function
- At the body tag
onload="ExampleFunction()"at Page2.html <script>window.onload=ExampleFunction</script>inside the body
but both are not working.
When using jQuery Mobile, you don’t use
onloadorready, you usepageinit: