18 January 2026:


This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.



Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.

Firefox and IE differences in script

edited November -1 in Sahi - Open Source
Hi,

I have recorded the script in IE and when I am playing in IE 7.0 it works fine, but when I run in Firefox 3.6 the script fails. Rerunning the record in FF 3.6 shows the properties of some of the elements are failing.

Can some one help me regarding it.

EX: 1
IE 7.0

_setValue(_textbox("j_username"), $LoginID);
_setValue(_password("j_password"), $Password);
__click(_div("Log In[1]"));

FF3.6
_setValue(_textbox("j_username"), $LoginID);
_setValue(_password("j_password"), $Password);
__click(_div("Log In"));

Any suggestions or help would be great.

Regards
Pranav

Comments

  • narayannarayan Administrators
    Hi Pranav,

    1) Could you share the HTML of the page (or the part with Log In div) please?
    2) Which version of Sahi are you using?
    3) Is the page rendering differently on IE and Firefox? Could you send us screenshots of the page and its html source (via view source) to support@sahi.co.in?
    4) Why are you using __click instead of _click?

    Regards,
    Narayan
  • 1. source

    <div class="loginButton">
    <spring:bind path="basicAuthentication.password">
    <a href="#" onclick="submitLogin()">
    <div class="loginButtonButton">
    Log In </div>
    </a>
    <script>
    function keyunicode(e){
    var unicode=e.keyCode? e.keyCode : e.charCode
    if(unicode == 13){//if Entered key is pressed
    submitLogin();
    }
    }
    function submitLogin(){
    document.loginComponentForm.submit();
    }
    </script>
    </spring:bind>

    </div>
    </form>
    </div




    2. Sahi Version :2010-03-21

    4. what is the difference between click and click?

    -- let me know if I missed anything

    Thanks for the help
    Pranav
  • narayannarayan Administrators
    Pranav,

    4) In your first post, click starts with two underscores (__click) instead of one (_click).

    Regards,
    Narayan
  • narayannarayan Administrators
    Hi Pranav,

    Could you try with the latest build for the div problem? We have made a few fixes around object index based identification.

    Regards,
    Narayan
Sign In or Register to comment.