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.

browser info

jason.hamerjason.hamer Members
edited November -1 in Sahi - Open Source
I know I can get the script status and the script name... is there something I can call to get the browser information??

Comments

  • AkshadaAkshada Members
    Hi Jason,

    I hope this helps!!
    http://sahi.co.in/forums/viewtopic.php?id=2355

    Regards,
    Akshada
  • globalwormingglobalworming Moderators
    edited May 2011
    Hi jason

    yes you can, there is an function _scriptName() in the Sahi API... I hope it works.
    for browser information you could use navigator.appVersion
    [Edit] or just follow the link above :)

    Regards
    Wormi
  • I have tried the code below and it does not return anything

    $diag = _sahi.getDiagnostics();

    I don't mind using navigator.appVersion but dont understand how could someone give me an example. I am simply wanting to create a variable that tells the browser I am using and the version of that browser.
  • narayannarayan Administrators
    You can use the _isIE() _isFF() etc. APIs to check which browser it is.

    To get navigator.appVersion

    var $appV = "";
    _set($appV, navigator.appVersion);
    _alert($appV);

    Regards,
    Narayan
  • First thank you for the product Sahi is awesome!!

    secondly thank you for the help.. it is greatly appreciated.
  • narayannarayan Administrators
    Thanks! : )
Sign In or Register to comment.