Hey guys,
I've done this so many times before but I can't seem to get it working!! All I'm trying to do is in the JavaScript at the top change a span tag to whatever the current window location is but it doesn't work!
<div id='Box' class="whitebox">
<div class="position">
<div name='domainBlock' id="textBlock">
<h1 align="center">Your Domain</h1> <br />
<span name="siteDomainName" id="domainNameText"></span>
</div>
I've tried EVERYTHING to change the value and I do not know why it will not change. The Span Tag is nested within two divs so I am not sure if that matters and I do not have a form element so I am not sure if that is relevant.
I've tried:
var myForm = document.getElementById("domainNameText");
myForm.innerHtml = window.location;
//and
var myForm = document.getElementByName('siteDomainName');
But it causes a script error. Do I need to go down to the child elements to change this? any advice?