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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T09:05:28+00:00 2026-06-10T09:05:28+00:00

I want to target this input and change it dynamically with jQuery: <select id=sub_cat

  • 0

I want to target this input and change it dynamically with jQuery:

<select id="sub_cat" style="" name="sub_cat">
<option selected="selected" value="-10">All</option>

I want to be able to change ‘All’ with an if statement based on different variables. Is this possible with jQuery? And how? Any help is appreciated. Thanks

  • 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-10T09:05:29+00:00Added an answer on June 10, 2026 at 9:05 am

    jsFiddle Example

    var option = $('#sub_cat').find('option:contains("All")');
    option.text('New Text');
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I can check for iPhone with this code: (navigator.userAgent.match(/iPhone/i)) But I want to target
I'm not sure how to target the element I want in this case: var
I want to implement DropTargetListener with a JTable as a target. This is roughly
I want preserve original value of target field and use json_decode to use following
i want to change a link's href based on the user's input, so far
I'm searching for a jQuery plugin that does this. for example: <label><input type=checkbox depends_on=foo=5
this jquery code works fine for me in jquery format. I want convert this
In the HTML5 INPUT type='number' the user can change the value by clicking on
I have the following hidden form: <form id='export_svg_container_single_form' action='exportSVG.pl' method='post' target='_blank' style='display:none;'> <input type='text'
i want to target closest div from my anchor tag. so in order do

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.