WebPagetest Forums
Could not script a click - Printable Version

+- WebPagetest Forums (https://www.webpagetest.org/forums)
+-- Forum: Web Performance (/forumdisplay.php?fid=3)
+--- Forum: Discuss Test Results (/forumdisplay.php?fid=4)
+--- Thread: Could not script a click (/showthread.php?tid=14605)



Could not script a click - rmitvn - 11-19-2016 11:11 AM

Dear friends,
Over a week, I tried to script a testing to click an item on this page:
https://democlass.rmit.edu.vn
I ran either this script:
navigate https://democlass.rmit.edu.vn/#/home
clickAndWait innerText=Học sinh

or this script:
navigate https://democlass.rmit.edu.vn/#/home
clickAndWait innerHtml=Học sinh

but the result is "content breakdown" after the second command.
I tried to stimulate the click option "I am a student" but not sure the script was correct.

Anyone help?
I appreciate your kind response.
RMITVN


RE: Could not script a click - andydavies - 11-20-2016 06:03 AM

This should work for you

navigate https://democlass.rmit.edu.vn/#/home
execAndWait document.querySelectorAll(".hocsinh")[0].click()