Assuming you have the span to display time is existing in the master file.
You are trying to set its time from the two separate files which are referencing this master file and are situated at two different locations as mentioned below :-
i) When accessing from the aspx file which is at root and referencing the master file.
ii) accessing from the aspx file which is inside a folder existing at root and referencing the same master file
So here i think the main issue is the core jQuery file and the JavaScript file which holds the code to set the time to the span, whose path differs for both of the aspx files.
So we may go for referencing the JavaScript files as follows :-
<script src="../Scripts/jquery-2.0.3.js"></script>
Same can be done for other JavaScript files which you are using to refer from master file.
Here the main thing to be marked is the two dots just before the URL for the JavaScript file which signifies the root directory of the project and so as to direct them to refer the file always from root.
Hope this will be of work for you.