Jump to content

[SOLVED] randomized xpath


Recommended Posts

Hello. On this site:

Spoiler

del

 

account name form and money amount form have random xpath every time like this //*[@id='id_random text']

 

_WD_Navigate($sSession, $sURL)

Sleep(3000)

$sElement = _WD_FindElement($sSession, $_WD_LOCATOR_ByXpath, "//*[@id='TCSid_h6Sgf_67Hg']")
_WD_ElementAction($sSession, $sElement, 'value', $sLogin)

Sleep(1500)

$sElement = _WD_FindElement($sSession, $_WD_LOCATOR_ByXpath, "//*[@id='TCSid_oYhI_7tsto']")
_WD_ElementAction($sSession, $sElement, 'value', $sMoney)

Sleep(1500)

$sElement = _WD_FindElement($sSession, $_WD_LOCATOR_ByXpath, "/html/body/div[1]/div/div/div[2]/div[1]/div[2]/div[2]/div[3]/div/div[2]/section/div/div[1]/div/form/div[3]/div[1]/button")
_WD_ElementAction($sSession, $sElement, 'click')
_WD_LoadWait($sSession, 0)

 

Maybe someone can help me 🙂

Edited by auitden
solved
Link to comment
Share on other sites

4 minutes ago, Danp2 said:

Have you tried using the element's name instead?

I triend xpath, fullxpath and ccs selector with no result :(

Element's name tried too, but I think I used incorrect syntacsis. Can you give me example for one lement?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...