Linked Questions

9 votes
4 answers
1k views

I have the following jQuery selector: $("a[href^='http://'],a[href^='https://']"); Is it possible to change this so that I don't need to specify a[href^= twice? For example, something like: $("a[...
Curtis's user avatar
  • 104k
2 votes
3 answers
2k views

I have elements. I know for sure they will have a class 'fc-id#' where '#' is a number. I need to somehow get that number. This will always be the first class of the element. Is there some way to ...
jmasterx's user avatar
  • 54.5k
0 votes
3 answers
3k views

I have the following script: <div> <p id="example1"></p> <div></div> <p id="example2"></p> <div></div> <p id="example3"></p>...
user610983's user avatar
1 vote
4 answers
584 views

$("#slide") code formating i've got something like this, i want my function to select all id's starting from slide, slide1, slide2 etc. In bash there is slide*, which does that job, is there anything ...
Miyagi's user avatar
  • 127
2 votes
2 answers
2k views

I want to match input fields that match the following pattern: a_profile_contact_attributes_addresses_attributes_0_address b_store_contact_attributes_addresses_attributes_3_address ...
Donato's user avatar
  • 2,787
1 vote
5 answers
2k views

<input name="Indian_Karnataka_Bangalore" value="Bangalore" /> <input name="Indian_Andhra_Hyderabad" value="Hyderabad" /> <input name="Indian_Kerala_Trivandrum" value="Trivandrum" /> &...
Syed's user avatar
  • 25
-2 votes
2 answers
3k views

<div class="A1"> <div id="child1">A1-1</div> <div id="child2">A1-2</div> <div id="child3">A1-3</div> <div id="child4">A1-4</div> ...
cppit's user avatar
  • 4,564
2 votes
2 answers
2k views

I'm trying to first clear the class of all options and then add a class to the option with the corresponding letter. Here's my function: function setAnswer(b, c){ $('#'+b+' .option')....
Atom Vayalinkal's user avatar
3 votes
1 answer
2k views

It is possibile to use this selector $( "input[name~='man']" ) to identify any input in page which name contains the word 'man' but if i need to select, instead of a single word pattern i.e. 'man', a ...
Sasha Grievus's user avatar
2 votes
8 answers
876 views

I am looking for a regex for Javascript to search for text ("span" for example) in HTML. Example: <div>Lorem span Ipsum dor<a href="blabla">lablala</a> dsad <...
Bebna's user avatar
  • 119
5 votes
2 answers
2k views

I want to look for &copy; in an HTML document, and basically get the entity the copyright is attributed to. The copyright line shows up a couple of different ways: <p class="bg-copy">&...
tarayani's user avatar
  • 193
0 votes
2 answers
1k views

Say in my html I have the following anchor tags: <a href="#fragment1"> link 1 </a> <a href="http://someExternalResource.com"> link 2 </a> <a href="#fragment2"> ...
Andrew Kim's user avatar
  • 3,361
0 votes
3 answers
2k views

If my title seems stupid, forgive me. I'm a newbie in jQuery and I don't know to explain my problem using the correct jQuery terms. So I asked this question a while ago and got the perfect answer. ...
Annie Lagang's user avatar
  • 3,235
2 votes
4 answers
870 views

I would like to apply a class to each div with a certain id if that id ends with a even number. Also i want to apply a different class to the ones that end with a odd number. Ideally it would be great ...
salmon's user avatar
  • 43
0 votes
2 answers
664 views

I want to match these tags: <div>03-24-2010</div> <div>04-23-2011</div> With jquery: ("div:contains([0-9]{2}-[0-9]{2}-[0-9]{4})") What do I need to do to the regular ...
JMC's user avatar
  • 1,697

15 30 50 per page