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 6953447
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T14:28:48+00:00 2026-05-27T14:28:48+00:00

is it possible to search for the a control on a webform, where you

  • 0

is it possible to search for the a control on a webform, where you just want to match “anything” for part of it ie:

I have various buttons on a page – which take the id format: ID#(id1)#(id2)#(date) – for example:

ID-8258-3103-2011-12-18
ID-8258-3104-2011-12-18
ID-8258-3105-2011-12-18

I want to pass the (id1) and (date) in a querystring, and then have jQuery search for the first control on the page, which matches the (id1) and (date) and any (id2) – so for example, I pass 8252 and 2011-12-18 – so how would I find the first control above, from jQuery?

$("#ID-8252-????????-2011-12-18")
  • 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-05-27T14:28:49+00:00Added an answer on May 27, 2026 at 2:28 pm

    Instead of using the #id selector, you can combine multiple attribute selectors, which filters the id attribute (one for the beginning of the id, one for the end):

    $('[id^="ID-8258"][id$="2011-12-18"]').addClass('found');
    

    To select only the first match, use the :first selector (not the same as the :first-child selector!)

    $('[id^="ID-8258"][id$="2011-12-18"]:first').addClass('found');
    

    See http://api.jquery.com/category/selectors/ for reference.

    Example:

    http://jsfiddle.net/wbLZ8/3/

    It seems that these selectors can be used even with IE7, if you want to use them in plain CSS.

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

Sidebar

Related Questions

Is it possible to embed an inline search box into a web page which
I have a search box with JavaScript and CSS tabs on it which control
I have the following scenario. I have a search page which is split into
I have a question about IPTC metadata. Is it possible to search images that
What is the possible ways to control search engine reverence in MySQL? let us
I load a user control in a web page which throws an exception: this.LoadControl(someusercontrol);
I have an existing website with a lucene search which works perfectly adequately, however
Is it possible to search for an object by one of its properties in
Is it possible to search every field of every table for a particular value
Is it possible to search for a phrase of the kind Searching is fun

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.