I've been using IE.au3 for a while and am now trying to learn how to do all of the same things I need to do with FF.au3. I'm having some trouble figuring out how to retrieve some element properties like innerHtml, because the returned value appears to be the empty string no matter what I try. The code segment I'm currently running is this:
Local $splashDiv = _FFObjGet("isc-login-swoosh", "class")
MsgBox(0, "", _FFCmd(".getElementsByClassName('isc-login-swoosh')[0].innerHtml"))
Local $array = _FF_ElementGetPosition("getElementsByClassName('isc-login-swoosh')[0]")
If (@Error == 0) Then MsgBox(0, "", $array[0] & ", " & $array[1])
Running from SciTE, this is the output I get to the console:
__FFSend: try{window.content.frames["top"].document.getElementsByClassName('isc-login-swoosh')[0]?1:0;}catch(e){'_FFCmd_Err';};
__FFRecv: 1
__FFSend: try{window.content.wrappedJSObject.frames["top"].document.getElementsByClassName('isc-login-swoosh')[0].innerHtml}catch(e){'_FFCmd_Err';};
__FFRecv:
__FFSend: try{repl.inspect(FFau3.findPos)}catch(e){'_FFCmd_Err';};
__FFRecv: <undefined> is empty
__FFSend: try{FFau3.findPos=function findPos(obj){var curleft=curtop=0;if(obj.offsetParent){do{curleft+=obj.offsetLeft;curtop+=obj.offsetTop;}while(obj=obj.offsetParent);return curleft+' '+curtop;}}}catch(e){'_FFCmd_Err';};
__FFRecv: function() {…}
__FFSend: try{FFau3.findPos(content.document.getElementsByClassName('isc-login-swoosh')[0])}catch(e){'_FFCmd_Err';};
__FFRecv: 490 256
So I can confirm that the element exists and I can get its position using the _FF_ElementGetPosition() function. Using Firebug, I've also checked that the innerHtml property should not be empty, and I have code using IE.au3 that returns the innerHtml property as expected. What gives? What am I doing wrong?