Website Inspection: How to identify generic class based on unique text?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements

Welcome Idira to LIVEcommunity!

Our community just got stronger! Explore new identity security resources, connect with experts, and discover more ways to learn and collaborate.

Meet Idira

Website Inspection: How to identify generic class based on unique text?

L3 Networker

I'm attempting to reconcile my admin account for a webapp. However, the webapp's user page uses a table with generic classes for every user listed. So, I can't just tell my ElementsData.ini file to look for a specific class to click on because all of the users in the list have the same class. Please see the HTML code that I'm referring to:

<a href="#" class="model-title entity-edit-link">admin</a>

Is it possible to target the text "admin" on the page IF it has the model-title class associated with it? I'm not sure how to do that in the ElementsData.ini file.

 

Basically, I just want CyberArk to "click" on the admin link to pop out the Edit User page.

1 REPLY 1

L3 Networker

I was able to do what I wanted to do without referencing two different elements. I was able to reference the admin link with this code here and simulate a click:

//a[contains(text(),'admin')]>(Click)(searchby=xpath)

Found a very helpful Chrome addon called Selenium IDE. I highly recommend it for anyone that is creating webform syntax for CPMs.

  • 372 Views
  • 1 replies
  • 0 Likes
Like what you see?

Show your appreciation!

Click Like if a post is helpful to you or if you just want to show your support.

Click Accept as Solution to acknowledge that the answer to your question has been provided.

The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!

These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!

The LIVEcommunity thanks you for your participation!