My project includes files and folders, like:
--My Project
|--index.htm
|--index.js
|--auth-system(folder)
|--signin.html
|--signup.html
|--signout.html
|--auth.js
I want to change some element values of index.htm using auth.js. My code in auth.js is like:
document.getElementById('userName').value = "ok"
where userName is the id name of a list element in index.htm
<li class="nav-item active">
<a id="userName" class="nav-link" href="#" target="myFrame">User</a>
</li>
I included auth.js in the index.htm by adding
<!-- Authentication js -->
<script type ="text/javascript" src="auth-system/auth.js"></script>
but it doesn't work...
Can you help me? thanks!