closest Questions

3

Solved

I have table rows with data and buttons. http://codepen.io/leongaban/pen/nuIkd Each button corresponds to each row, also when you click a button it changes class names from hide to un_hide the nex...
Juliettejulina asked 17/12, 2013 at 17:44

3

Solved

I have a large HTML form with multiple input fields (one in each row). Among these I have several fields with a specific class that appear left from a button. There are no other buttons or fields ...
Draggletailed asked 3/12, 2013 at 16:52

2

Solved

I have two data frames, logger and df (times are numeric): logger <- data.frame( time = c(1280248354:1280248413), temp = runif(60,min=18,max=24.5) ) df <- data.frame( obs = c(1:10), time = ...
Sc asked 13/11, 2013 at 15:28

2

Solved

I am trying to do make some text show when a text input is on focus, but the closest(); method doesn't seem to be working. I have done a JS Fiddle for you to look at. and here is the code also. ...
Accompaniment asked 4/7, 2013 at 9:41

1

Say I have 2 matrices in matlab : A = [1 4 6 9 11 13 15 18 21] B = [2 10 19] Is there a function I can use so that, for every element in B, I am able to find the index of the closest val...
Lapstrake asked 16/4, 2013 at 20:57

2

Solved

I have a link which posts some data to a controller. It is working fine and updates the data. But I want to change the css of the parent div but it is not happening. I have tried a lot of variation...
Zodiac asked 14/10, 2012 at 0:17

2

While hacking my free-time project I stumbled upon a puzzling jQuery behaviour. I have a custom validation plugin written and working. In the plugin I wanted to implement some functionality using ...
Stereogram asked 14/6, 2012 at 9:23

3

Solved

I have a listener for click events from which I need to exclude some elements. Right now my list is growing, so I'm looking for a better way to "bundle" multiple elements in a selector. This is w...
Godman asked 21/3, 2012 at 12:52

3

Solved

jQuery has a lovely if somewhat misnamed method called closest() that walks up the DOM tree looking for a matching element. For example, if I've got this HTML: <table src="foo"> <tr> ...
Cockneyfy asked 3/11, 2011 at 23:28

1

I needed to find the nearest element, relative to another element. I wanted a generic function not locked to a spesific tree structure. Maybe it already exists within jQuery and if so please show m...
Majestic asked 1/11, 2011 at 23:0

3

Solved

I have multiple buttons on my page with the same class. When I click on a button I want to get the value of the nearest input box (remember there are multiple input boxes and buttons on my page wit...
Marabout asked 28/8, 2010 at 17:37

1

Solved

I know how to implement n log n closest pair of points algorithm (Shamos and Hoey) for 2D cases (x and y). However for a problem where latitude and longitude are given this approach cannot be used....
Tunnell asked 20/8, 2011 at 3:39

2

Solved

I am trying to iterate to the first ancestor containing the class ‘sys-form-row’. I am able to get the row containing class="sys-form-row" using the following: objBack = $('#txtMyBox2').parent()...
Statist asked 28/7, 2011 at 15:37

5

I'm returning mobile phone data based on the user agent. But in an instance where the useragent is not stored (newer version of phone or software) I want to be able to return the closest match, a b...
Universality asked 8/7, 2011 at 9:17

2

Solved

I have a 4 dimensional array, i.e., data.shape = (20,30,33,288). I am finding the index of the closest array to n using index = abs(data - n).argmin(axis = 1), so index.shape = (20,33,288) with t...
Insupportable asked 27/4, 2011 at 1:31

3

Solved

How would you write the Jquery to get the closest div that actually has an ID defined?
Marbling asked 23/2, 2011 at 19:36

1

Solved

i have: <ul class="rating"> <h3>Like this</h3> <li class="rating-number"> <div id="iLikeThis" class="iLikeThis"> <span class="counter">2</span> </...
Herophilus asked 15/2, 2011 at 12:39

1

Solved

I'm trying to do some jQuery which will find images inside text, wrap the image inside a div and then move it to another div, yet I can't seem to get it working. Here's the code that I have so far...
Drollery asked 4/11, 2010 at 23:42

4

Solved

I'm attempting to do some calculations for a "running total", this is my code: $('.quantity_input').live('change',function(){ var ValOne = parseFloat($(this).val()); var ValTwo = parseFloat($(...
Marney asked 4/11, 2010 at 13:6

2

Solved

I was testing with parent() and closest(), none work within function. TD stays the same, no change using this method: $.get('form.php', function(data){ alert(data); $(this).closest('td').html...
Dugger asked 13/9, 2010 at 16:18

2

Solved

using jquery, how would i find the closest match in an array, to a specified number For example, you've got an array like this: 1, 3, 8, 10, 13, ... What number is closest to 4? 4 would return ...
Christianachristiane asked 24/8, 2010 at 21:41

4

Solved

Hope someone can advise. Having issues trying to remove a row once a link has been clicked. HTML <table> <tr><td>Some Data</td><td><a href="#" class="remove-row&...
Lantana asked 23/8, 2010 at 14:58

3

Solved

So lets say I have 10,000 points in A and 10,000 points in B and want to find out the closest point in A for every B point. Currently, I simply loop through every point in B and A to find which on...
Skill asked 14/4, 2010 at 21:31

1

Solved

<td width="162"><span class="required">*</span> Name:</td> <td width="407"> <label> <input id="store_name" class="text_field alnum" type="text" minlength="3...
Honoria asked 14/10, 2009 at 10:53

2

Solved

While working a project tonight, I ended up using one .js resource file for two different pages. One page contains a textarea within a div, and another contains a textarea within a td. Wanting to w...
Fractionate asked 31/8, 2009 at 0:50

© 2022 - 2024 — McMap. All rights reserved.