I'm including the same javascript file in the head of 2 html files:
<script src="js/app.js"></script>
And html page1 then links to html page2. But when you follow the hyperlink to page2, the code in the javascript file doesnt get called again when page2 loads. And even when I try to add a block of code in the head or body of html file 2 to call a function in the JS file, it never executes.
Am I doing something wrong?
EDIT: Heres the code http://jsfiddle.net/dL6gpveL/1/
EDIT2: So everything works normally when I dont have JQuery Mobile included. Any idea why this would happen? Its version 1.4.5
EDIT3: Sorry I should have said I was using jquery mobile in the first place.