Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8699153
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T01:52:43+00:00 2026-06-13T01:52:43+00:00

I am currently working on Eclipse using java bindings and i’m automating an e-commerce

  • 0

I am currently working on Eclipse using java bindings and i’m automating an e-commerce website. I am using Selenium 2 (Webdriver) to write my automation scripts and I’m having an issue trying to get a particular element via css. My preference is css because of the unstable nature of xpath (especially with the changes implemented on our site weekly). Can anyone please assist me? Thanks in advance. There are two buttons i need to click and are both similar. The first one is the continue button:

<td class="content" style="vertical-align: bottom; ; background: url(http://g-ecx.images-amazon.com/images/G/01/digital/video/avod-1-5/dp-sprite-total._V156422041_.png) no-repeat -3px -153px; padding: 0px 4px 0px 11px;">       Yes, continue with my purchase     </td>

The second one is the cancel button:

<td class="content" style="vertical-align: bottom; ; background: url(http://g-ecx.images-amazon.com/images/G/01/digital/video/avod-1-5/dp-sprite-total._V156422041_.png) no-repeat -3px -181px; padding: 0px 4px 0px 11px;"> Cancel </td>

As you can see, they both have similar structures but only differ on the text. Now i can go as far as using this – css=td.content

but this brings both elements up and the script fails. What i need to do is input something that would use the text. Thank you in advance for your help

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T01:52:45+00:00Added an answer on June 13, 2026 at 1:52 am

    CSS selectors don’t work this way. There was something called :contains() but it was dropped. You could add a second class to each td element like this:

    <td class="content action_yes"...>
    <td class="content action_no"...>
    

    Then your CSS selector would look like this (in jQuery only because it’s so clean, this approach is standard CSS)

    $('.action_yes')
    $('.action_no')
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm currently working on a plug-in for Eclipse that translates some custom Java code
I'm currently working on an Android app using Eclipse on a Mac OSx. I
I am currently working on a basic app using eclipse as my IDE. I
I'm currently working with J2me by Mobile Tools for Java (MTJ) on Eclipse. My
I'm currently working on a project in Ruby on Rails (in Eclipse) and my
Currently, I have a machine on which I am working in Eclipse, it says
Currently working with the following package structure: /package __init__.py final.py /write __init__.py write.py /data
Currently working with NSURLConnection. Found a great website showing important delegate methods coming with
I'm currently experiencing a problem with 'hot code replace' not working on Eclipse Galileo
I am currently working on a distributed application using the following components: 1.tier: Database-Server

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.