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

  • Home
  • SEARCH
  • 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 8582185
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T21:13:50+00:00 2026-06-11T21:13:50+00:00

I would like to select the second or nth option from a select element

  • 0

I would like to select the second or nth option from a select element with the IE driver using css selector.

I tried the following but it doesn’t work.

option:nth-child(1)

If I provide a value, it works, but I don’t know the value all the time so I like to select by nth-child.

option[value=’1′]

the error i got on IE8 is javascript error:

Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.3; .NET4.0C; MS-RTC LM 8; .NET4.0E; Tablet PC 2.0)
Timestamp: Wed, 26 Sep 2012 23:34:46 UTC

Message: Invalid argument.
Line: 30
Char: 96
Code: 0
URI: http://blah/foo.aspx
  • 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-11T21:13:52+00:00Added an answer on June 11, 2026 at 9:13 pm

    This is perfectly expected. Internet Explorer 8 supports querySelector() and querySelectorAll(), so the IE driver relies on the browser’s native implementation of CSS selectors, which means you’re limited to whatever level of CSS selector support is provided by the browser. In the case of IE 8, the browser does not support CSS3 selectors, so the IE driver will not work with any CSS3 selectors. Of course, nth-child() is part of the CSS3 specification, so using the IE driver with IE 8 will not support nth-child(). As for what selectors are supported by which browsers, there is a great reference at quirksmode.org which provides a nice summary of each of the selectors and which browsers they are supported in.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to run something like: select * from table where field in
I would like to select a row from the database based on two input
I would like to select a node and modify its attributes and child-nodes using
I would like to select an element inside the td of one of my
I would like to select a row from 2 different tables that are relational.
I will have 3 <select multiple=multiple> and I would like to fill them using
I would like to select only one class from severals with the condition that
I have a scenario where I would like to select rows from a table
I am using JFlow for my content slider and would like to select one
I would like to select the XPath of a tag and the content of

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.