I am trying to access elements of one frame to another by doing the following:
function GetClientId(strid) {
        var i = 0;
        var eleName;
        var breakout = 0;
        for (j = 0; j < parent.right.document.forms.length; j++) {
            for (i = 0; i < parent.right.document.forms[j].length; i++) {
                eleName = parent.right.document.forms[j].elements[i].id;
                pos = eleName.indexOf(strid);
                if (pos >= 0) {
                    breakout = 1;
        if (breakout == 0) 
            eleName = "";
        return eleName;
But I have an asp page that is rendered in the frame with the following html and the <a> is not being picked up with the above code:
HTML Code:
<a id="ctl00_btnLogin" tabindex="3" class="button loginbutton" class="loginbutton" onkeypress="return WebForm_FireDefaultButton(event, 'ctl00_btnLogin');" href="javascript:WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions(&quot;ctl00$btnLogin&quot;, &quot;&quot;, true, &quot;LoginControl&quot;, &quot;&quot;, false, true))"><span>Log In</span></a>
Why is this? Is it because <a> are not part of document.forms? More importantly how would I go through all html tags?