I was trying to avoid retyping my head, nav and footer sections in my html files with js and got a little carried away … but I can’t get my contact button to validate the form.
The html/css/js bundle is here:
If you download and launch the index.html in live server with something like vscode … it works.
The pages are added dynamically to the screen as you click the nav text as the top.
But, I can’t figure out how to add functionality to the contact page. I have a nice form validator js that I was going to use to capture my form items by id and validate them.
However, I can’t seem to get basic js functions to work on the returned contact us page. Even basic script tags included in the returned template literal do not create funcntionality on the bottom like onclick=“doSomething();”
When I return script tags in template literals – Ii can’t seem to get it to work.
Any thoughts on how I might access a click functionaltiy on the contact us button?