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.

how to get url of current page?

ponsoponso Members
edited November -1 in Sahi - Open Source
anyone know the code to get the URL of the current page I'm on?

Basically I'm trying to test 301 redirect so I was going to _navigateTo, let it redirect and compare the url. Any better ideas are welcome.

thanks!

Comments

  • haha I may have found it!

    var $x;
    _set($x, window.document.location.href);
  • narayannarayan Administrators
    Hi Ponso,

    Your solution is right!

    Regards,
    Narayan
This discussion has been closed.