How to create Dynamic Xpath in Selenium Part 2

Поделиться
HTML-код
  • Опубликовано: 21 ноя 2024

Комментарии •

  • @snehasingh9396
    @snehasingh9396 7 лет назад +3

    Why didn't i find your channel before! Your videos are so helpful. Really appreciate the effort you have put in to make the tutorials so easy to follow. Thanks!

  • @swayambikash4981
    @swayambikash4981 8 лет назад

    Thanks a lot for the video.......Ur way of explaining is simply fantastic.......Please share the link of part 3 of this video series

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад

      +Swayam bikash Thanks Swayam will upload soon.

  • @gandharavkatyal822
    @gandharavkatyal822 7 лет назад +1

    thanks mukesh , u did a great job , hats off!!

    • @Mukeshotwani
      @Mukeshotwani  7 лет назад +1

      Thanks Gandharav keep visiting and let me know if you need any help from my side.

  • @pavankumarsharma2346
    @pavankumarsharma2346 9 лет назад +1

    Nice video for Xpath, Thank you.

  • @shreyanshjain2347
    @shreyanshjain2347 9 лет назад +2

    nice video, please post video tutorial on "Selenium Grid". Thanks! :)

    • @Mukeshotwani
      @Mukeshotwani  9 лет назад +1

      +Shreyansh jain so many video's in pipeline will upload soon :)

    • @nagi4a5
      @nagi4a5 9 лет назад

      +Mukesh otwani i also waiting for "Selenium Grid".

  • @kirantherise1
    @kirantherise1 8 лет назад

    Thanks Mukesh....Many Questions get answered....

  • @harshbhasin13
    @harshbhasin13 8 лет назад

    Hi Mukesh,
    Excellent videos mate!!! Great help.....

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад

      +Harsh Bhasin thx Harsh

    • @harshbhasin13
      @harshbhasin13 8 лет назад

      Hi Mukesh, I have sent u a mail to seek some help on a website I am currently testing. Could you please provide me appropriate solution to my query.
      Thanks

  • @srinuckograndstreet4025
    @srinuckograndstreet4025 6 лет назад

    Mukesh you are using //following:: but as per the syntax we should use /following:: and even i have used with /following and its working

  • @LeRune_
    @LeRune_ 8 лет назад +1

    Great Videos!!!

  • @Shashikala.gowda26
    @Shashikala.gowda26 8 лет назад

    Thank you so much for nice tutorials ....

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад

      Welcome Shashikala :) Happy Navratri.

  • @hariprasad4946
    @hariprasad4946 6 лет назад +1

    Nice video Mukesh...
    One clarification, for every element on a page if possible we can create multiple relative xpath.am I right?

  • @prirav64
    @prirav64 8 лет назад +1

    Thanks! HELPED ME A LOT!

  • @ATULMYSELF79
    @ATULMYSELF79 8 лет назад +1

    thnx , really helpful...........

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад

      +Hum Tum Thank you :) Keep visiting

  • @madhusmita271
    @madhusmita271 8 лет назад

    Thanks for this video...learned so much from it :)

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад

      +Madhu smita Thanks Madhu hope next tutorial will also give deep insight of Selenium

  • @ashokgunja4799
    @ashokgunja4799 8 лет назад

    Thank you bro...realy nice tutorial..!

  • @fraferf1
    @fraferf1 7 лет назад

    Very useful and interesting. Thanks!

    • @Mukeshotwani
      @Mukeshotwani  7 лет назад

      +fran ferris Thanks Fran keep visiting

  • @naqashzafar6181
    @naqashzafar6181 7 лет назад

    Thank you from Pakistan

  • @madhurichebbi2769
    @madhurichebbi2769 6 лет назад

    This video helped me a lot. Thank you so much..

  • @rajeshdevan6051
    @rajeshdevan6051 6 лет назад

    Nice explanation Sir thank you then without using fire bug how we use these following, ancestor, preceding Sir can you make video for that?

  • @chinnikrishnad6736
    @chinnikrishnad6736 8 лет назад

    Thanks for nice tutorial

  • @rajnature198
    @rajnature198 8 лет назад

    thanks mukesh, Also plz suggest me how to click auto suggestion box?

  • @AmreshKumar-ng1rs
    @AmreshKumar-ng1rs 8 лет назад

    Hi mukesh,
    at 5:09 I noticed that using following::a is showing element which are written before element having id='menu-dashboard' as well(as u can notice scroll bar position). Then how following:: is showing only elements coming after id='menu-dashboard' element?

  • @adhongde1
    @adhongde1 7 лет назад +1

    how do i create xpath for below
    I did create //input[@type='text' and @placeholder='Filter value...' ] and 4 matching.

    • @Mukeshotwani
      @Mukeshotwani  7 лет назад

      Hi Abhay if you are getting multiple nodes then you have 2 solutions.
      1- Add some more property to get unique element.
      2- You can use index as well to get all values.

  • @bibhutijha1113
    @bibhutijha1113 7 лет назад +1

    hi Mukesh
    Could you please make a video for identifying elements in nested tables in IE

  • @NehaGupta-es8mb
    @NehaGupta-es8mb 8 лет назад

    Nice vedio. I want to ask if there is no locator for you how to identify the element on web page.

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад

      Hi Neha in that case you can use Text as well

  • @jayeshhoondlani3438
    @jayeshhoondlani3438 9 лет назад +1

    thanks alot ......

  • @narendrakumarmaddu
    @narendrakumarmaddu 7 лет назад

    Thank you so much for nice tutorials
    id is Dynamically changed.how to Write the Xpath

    • @Mani-oq2bj
      @Mani-oq2bj 7 лет назад

      if, id is dynamically changed, we can use starts-with(), contains()
      //input[contains(@id,'123')] or
      //input[starts-with(@id,'123')]
      if id is getting changed completely, then we have to choose another property instead of 'id'
      or better to use following concept

    • @narendrakumarmaddu
      @narendrakumarmaddu 7 лет назад

      Hi bro,first time id=123 and second id=654 continuous changed how to handle
      another property is not there

  • @socialmediahappy8697
    @socialmediahappy8697 3 года назад +1

    this nice tutorial
    How can I check the presence of element (Button) for many flight
    on listing there is so many flight
    how can we check the presence of button for many flighy
    give some example
    related to this

    • @Mukeshotwani
      @Mukeshotwani  3 года назад

      Hi Mate, you can use findElements.

  • @mahbubkhoda4615
    @mahbubkhoda4615 8 лет назад

    Hi Mukesh, your videos are great. How to get all the values of “Month” drop down for creating new Gmail account? I do not find any select tag over there. Thanks

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад +1

      Hey mahbub yes in that case get all elements in List and then iterate using loop and then click.

    • @mahbubkhoda4615
      @mahbubkhoda4615 8 лет назад +1

      Hi Mukesh, thanks for your response. I should have used findElements instead of findElement. Now the problem is solved. findElement returns single WebElement

    • @divyangjani7600
      @divyangjani7600 3 года назад

      @@mahbubkhoda4615 right

  • @mahajanram9608
    @mahajanram9608 7 лет назад +1

    thank you Mukesh

  • @wahidacheshty694
    @wahidacheshty694 Год назад

    Can you build a bdd framework from scratch and please execute some projects in some short videos

  • @prajktapund5666
    @prajktapund5666 4 года назад +1

    //label[text() ='Username or Email Address']//following::input[1]
    This XPath should highlight only one textbox. But it will return 2. Why?
    Currently I am using ChroPath.
    The only problem with label-tag. It will work fine with input-tag.

    • @Mukeshotwani
      @Mukeshotwani  4 года назад +1

      Hi Prajkta, many time you will face hidden webelements. I have dedicated video on this which will help you to deal with such scenario ruclips.net/video/2eEr0jtmpwE/видео.html

    • @prajktapund5666
      @prajktapund5666 4 года назад

      @@Mukeshotwani thank you🙂👍

  • @penbervideos9356
    @penbervideos9356 6 лет назад +1

    Thank you for the video!

  • @pareshnit6499
    @pareshnit6499 6 лет назад +1

    Hi Mukesh,
    Have u work on ext. Js UI framework, all elements in the dom are dynamic so can you please suggest me any other option

    • @Mukeshotwani
      @Mukeshotwani  6 лет назад

      Hi Paresh no experience on ext.js framework

  • @kirithigaulaganathan7415
    @kirithigaulaganathan7415 7 лет назад

    What is the difference between Ancestor or Precedent and Following or Descendent? Please explain with example. Thanks in advance

  • @jayantiborde899
    @jayantiborde899 5 лет назад +2

    Hello Sir,
    when I pass XPath like "//span[@class='select2-selection select2-selection--single']" selenium throws me error like "FAILED: register
    org.openqa.selenium.support.ui.UnexpectedTagNameException: Element should have been "select" but was "span" , what should i do.there is only class which is not working when created Dynamic xpath

    • @Mukeshotwani
      @Mukeshotwani  5 лет назад

      HI Jayanti, you can use following,preceding,parent properties to find xpath.

  • @rajnature198
    @rajnature198 8 лет назад

    nice video, can u plz tell me how to access footer element in chrome?

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад

      +Raju M Hi Raju you can press F12 which will start inspector the use CTR+ F it will start xpath search window.
      Then you can try your xpath which you want to search.

  • @sohamchakraborty4113
    @sohamchakraborty4113 3 года назад

    Sir, can you explain why there is a dot before every xpath expression in firefox ? , eg .//* .cant we not give directly // and then the expression ?In real time if we write on any ide like eclipse, how do we write it ?

  • @29Backfire
    @29Backfire 7 лет назад

    Hi , latest version of firefox doesn't support firebug or firepath , since we use developer tools to inspect elements , can u please provide details on how to work on developers tools .

  • @abdulshahid9071
    @abdulshahid9071 7 лет назад +1

    Hi Mukesh Could you please upload videos on selenium web driver 3.0 step by step

  • @srinunallamudi2096
    @srinunallamudi2096 8 лет назад

    Hi Thanks Buddy...

  • @shreyanshjain2347
    @shreyanshjain2347 9 лет назад +1

    thanks

  • @tuhin79
    @tuhin79 9 лет назад

    Thanks!

  • @ketakinaik9770
    @ketakinaik9770 7 лет назад +1

    Hi, Mukesh
    Can you please help with Error communicating with the remote browser. It may have died. error?

    • @Mukeshotwani
      @Mukeshotwani  7 лет назад

      Hi Ketaki always call quit or close method at last.

  • @TravelExplorerNX
    @TravelExplorerNX 3 года назад +1

    Hi Mukesh what is the normalize-space please check this xpath //a[normalize-space()='Create a new account'] i m not understand this

    • @Mukeshotwani
      @Mukeshotwani  3 года назад +1

      Hi Naved The normalize-space function strips leading and trailing white-space from a string, replaces sequences of whitespace characters by a single space, and returns the resulting string.

    • @TravelExplorerNX
      @TravelExplorerNX 3 года назад

      @@Mukeshotwani Thank you so much Mukesh Sir

  • @abhinavsharma2734
    @abhinavsharma2734 8 лет назад

    Thanks :)

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад

      Welcome Sharma ji :) Keep visiting.

  • @lokeshgupta8852
    @lokeshgupta8852 4 года назад

    One more question
    div
    span id 1
    span id 2
    div
    div
    span id 1
    span id 2
    div
    need to traverse from up to down and down to up .
    let me know the xpath

  • @varsharawat112
    @varsharawat112 7 лет назад

    sir i am working on salesforce technology, my website has developed on cloud, and it's a very tricky site, all elements having only single locator and i.e., class, or either id, i am not able to do automation, i have tried with so many xpath but none of them working, i am fadup now.

  • @zainubbehl5946
    @zainubbehl5946 8 лет назад

    Hi sir, can you recommend any good tutorial site on java or do have one that i can learn from?

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад

      +Zainub Behl I have almost 10 videos on Java on RUclips.. for rest javatpoint is best

    • @zainubbehl5946
      @zainubbehl5946 8 лет назад

      Thanks sir

  • @notchelve
    @notchelve 6 лет назад +1

    Hi Mukesh, Nice Videos. I tired using //*[id='c errontent-label']/label//following::textarea , it did not work. I got an Error'Element info: {Using=xpath, value=//*[id='content-label']/label//following::textarea}
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

    • @Mukeshotwani
      @Mukeshotwani  6 лет назад

      Is it matching with nodes?

    • @notchelve
      @notchelve 6 лет назад

      yes, i used word press website as in the video,but used chrome browser instead of Firefox

  • @pavankumarjampani
    @pavankumarjampani 6 лет назад

    Hi Mukesh, Thanks for the Video. Now Firepath is no longer available, is there any other way to write and evaluate my Xpath

    • @shilpawdhw
      @shilpawdhw 6 лет назад

      Hi Install the previous version of FF and disable auto update . Firepath is supported for 55.0 and older versions

    • @seatownrocks
      @seatownrocks 6 лет назад

      In Chrome, hit F12 to open dev tools. Select 'elements' tab. Type Ctrl-f for find. Enter your xPath then . Element(s) will be highlighted with the count.

    • @tugbars4690
      @tugbars4690 5 лет назад

      ChroPath is amazing for Chrome

  • @lokeshgupta8852
    @lokeshgupta8852 4 года назад

    Hi Mukesh,
    For exe:
    HTML
    Body
    Div
    Name
    Div
    Body
    HTML
    Kindly let me know the different xpath pattern to reach Name

  • @renikuntlasankeerth7433
    @renikuntlasankeerth7433 6 лет назад

    Please give me the above word press site link

  • @brianlara3447
    @brianlara3447 7 лет назад

    Hi everyone,
    any one help me,
    I am stuck with dynamic xpath which change its value after every execution PFB example for your reference
    //*[@id='dataTable']/tbody/tr[21]/td/div/i
    //*[@id='dataTable']/tbody/tr[22]/td/div/i
    //*[@id='dataTable']/tbody/tr[23]/td/div/i
    //*[@id='dataTable']/tbody/tr[24]/td/div/i
    so on ....
    please let me know know i can handle it
    thanks and waiting for positive response

  • @KrishnakishoreGunturu
    @KrishnakishoreGunturu 8 лет назад

    Great video
    Could you please provide the admin username and password

  • @ilzat-rozaji
    @ilzat-rozaji 7 лет назад

    For God's sake,
    I can not find this dummy website.
    Please send me the link

    • @rajarao6805
      @rajarao6805 7 лет назад

      you can use this website demos1.softaculous.com/WordPress/wp-admin/ username:admin password:pass

  • @padmavathi9242
    @padmavathi9242 7 лет назад

    Could you please give me the usename and password for the demowordpress

    • @swapnapradhan7072
      @swapnapradhan7072 7 лет назад

      admin and demo123
      previously it was working but not now.

  • @priyankag2354
    @priyankag2354 8 лет назад

    username :admin
    password:demo123
    is not working...couldn't working ?please provide me username n password

  • @hitendraparmar499
    @hitendraparmar499 8 лет назад

    Hi Mukesh
    here i its the xpath value. of compose the mail in gmail account.
    //div[@id=':gi']/div/div
    @id='This value is changed dynamic' every time
    how to handle this in selenium ide.also if we click on To label text in text also id is frequently changed.
    so plz help for the same.

    • @Mukeshotwani
      @Mukeshotwani  8 лет назад

      Hye Hitendra use text instead of ID

  • @Manish6059
    @Manish6059 7 лет назад

    Please take it as a feedback, a lot more could be done preparation part before presenting this video. You are switching to different concept while explaining something else, lack of good examples, objective of examples is not clear .

    • @Manish6059
      @Manish6059 7 лет назад

      For Ex : at 1.33 min, you took example of tag text area and suddenly switched to content text area and Xpath of content label is written aready and you just wrote "following" function to find the text area.But the Xpath of content does not match with any of the attributes mentioned in the html code