I got this jquery code where i clone some textfields everytime i click "btn_add", and i need the onchange function i wrote at the end to id_usd_value there works for every new clones i add but it's not working :  &lt;script type="text/javascript" src="jquery-2.1.4.js" charset="UTF-8" &gt;&lt;/script&gt;     &lt;script type="text/javascript"&gt;         $(document).ready(function(){             var obj = $('input[name="percent"]').length;              var n = 0;              $('#btn_add').click(function(){                 n++;                 $('table').append('&lt;tr id="btn_minus'+n+'"&gt;&lt;td&gt;&lt;input type="text" name="cost_element" value="0"/&gt;&lt;/td&gt;&lt;td&gt;&lt;input type="text" name="description" value="{{cost_element.description}}"/&gt;&lt;/td&gt;&lt;td&gt;&lt;input type="text" name="usd_value" id="id_usd_value" value="{{cost_element.usd_value}}"/&gt;&lt;/td&gt;&lt;td&gt;&lt;input type="text" name="pesos_value" id="id_pesos_value" value="{{cost_element.pesos_value}}"/&gt;&lt;/td&gt;&lt;td&gt;&lt;input type="text" size= 3 name="percent" id="id_rer_value" value="{{cost_element.percent}}"/&gt;%&lt;/td&gt;&lt;td&gt;&lt;input class="btn_minus btn btn-danger" name="btn_minus'+n+'" type="button" value="X"/&gt;&lt;/td&gt;&lt;/tr&gt;');                  obj = $('input[name="percent"]').length;             });              $('table').on('click',".btn_minus",function(){                 var id = $(this).attr('name');                 $('tr[id="'+id+'"]').remove();             });              $('.btn_delete').click(function(){                 location.href = "";             });              setInterval(function(){                 var percents = new Array();                  $('input[name="percent"]').each(function() {                     percents.push($(this).val());                 });                  var sum = 0;                 for(var i=0, l=percents.length; i&lt;l; i++) {                     sum = sum + parseInt(percents[i],10);                 }                  $('#msgValidar').empty();                 if(sum == 100){                         $('#msgValidar').append('&lt;h5 style="color: blue"&gt;Los valores de procentaje estan correctos.&lt;/h5&gt;');                         $('#btn_ok').removeClass('disabled');                 }else{                     if(obj != 0){                         $('#msgValidar').append('&lt;h5 style="color: red"&gt;Los valores de procentaje deben sumar exactamente 100%.&lt;/h5&gt;');                         $('#btn_ok').addClass('disabled');                     }                 }             }, 500);               $('#id_usd_value').on('change',                   function(e) {                         if($('#id_usd_value').val()&gt;0){                             $('#id_pesos_value').val(                               Math.round(                                 parseFloat($(this).val()) * parseFloat($('#id_rer_value').val())                               )                              );                         };                   }               );         });     &lt;/script&gt;   Any idea how ??, thanks for your help !
I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling with their width on mouse on/off.  This happens on page ready and works just fine.  The problem I have is that any select boxes I add via Ajax or DOM after the initial loop won't have the event bound.  I have found this plugin (), but before I add another 5k to my pages with a plugin, I want to see if anyone knows a way to do this, either with jQuery directly or by another option.
Yesterday, I have received two : Revival, and Self-Learner. However I was only notified of the Revival badge, because apparently the Self-Learner badge is not considered "".  What badges have their notification suppressed if the user has a 200-rep account somewhere on the Stack Exchange network, i.e. they won't trigger a new item in our achievements dialog? I would like to enable the root account on my Ubuntu installation.  I realize the security implications of this. Calculating a spherical polygon centroid How do the Hat Dash points work? Python BeautifulSoup findAll by "class" attribute I have been studying the pronunciation of Greek-derived words in English, and I've found an odd anomaly. There are (at least) two possible pronunciation patterns for plural word-forms that end in -&#8288;mata (which correspond to singular word-forms that end in -&#8288;ma).   Antepenult stress (expected)  It appears that it is always possible to place the stress on the antepenult (third-to-last) syllable, such as:    /ˈlɛmə/, /ˈlɛmətə/  /ˈskiːmə/, /ˈskiːmətə/  /ˌtɛrəˈtoʊmə/, /ˌtɛrəˈtoʊmətə/~/ˌtɛrəˈtɒmətə/  /ˈstɪɡmə/, /ˈstɪɡmətə/   This is what would be expected from  (I believe most or all of these words came through Latin before entering English), since the penultimate "a" in the original Greek words is short.  Maybe Latin vowel quality and stress rules are not very relevant; certainly, few English speakers know about them nowadays. And even with antepenult stress, some of these pronunciations do not seem to follow all of the traditional rules for pronouncing Latin-derived terms in English. I was reminded by some comments in this  that  in antepenult stressed syllables, we would expect tense ("long") vowels to be shortened due to  (TSL), yielding pronunciations like /ˌtɛrəˈtɒmətə/ (which I just noticed is in fact listed in the Oxford English dictionary) and ?/ˈskɛmətə/ (which is not). (Compare to genus~genera /dʒiːnəs/~/dʒɛnərə/, and perhaps opus~opera /oʊpəs/~/ɒpərə/). However, there are other Latinate plural forms that typically don't have trisyllabic laxing (matrices, also I think helices), or where both the lax- and tense-voweled pronunciations coexist (codices, apices), so I guess the apparent lack of it in schemata should not be surprising. (There are even some exceptions to TSL in singular nouns like obesity.)  Penult stress (unexpected)  The other pronunciation seems to exist only for a couple of words, in which the penultimate "a" is commonly stressed and broadened: stigma ~ stigmáta  (listed by both the Merriam-Webster dictionary and the ), and also sometimes schéma ~ schemáta /skiːˈmɑːtə/ (listed only by the ). (Neither the Merriam-Webster dictionary nor the Oxford Learner's Dictionaries list *"lemmáta").  I'm wondering why this pronunciation exists. It's an irregular plural either way, and putting the stress on the penultimate syllable creates a stress change between the singular and the plural forms.  (It's true that all of these words are rare, and some people might pronounce some of their plurals differently. The pronunciations I give here are simply the ones listed in dictionaries.)  The plural form "stigmata" is probably most common in religious or theological contexts (where it refers to the wounds of Christ), so at first I wondered if the penultimate stress was supposed to be closer to the original Greek pronunciation, but according to , the stress is on the antepenult in Greek as well.  So, what's up with this? Did the stress perhaps change in Latin over time, is this a tradition of Greek accentuation that I'm not familiar with, is this a simple matter of ignorance of the original position of the stress that has now become entrenched with time and usage, or is this somehow explainable by established English stress patterns? (For example, do English speakers have some natural preference for a penultimate stress on polysyllabic words?)  If nobody knows of a reason, I suppose I can just put it down to people encountering the word mainly in text, not knowing which syllable to stress, and choosing the penult because it sounds better to them.  (I asked this question a while back on , but nobody knew of any reason.) I upgraded from 16.04 to 18.04. When I press Ctrl+Alt+F3 I get the terminal which prompts for the username. When I type my username and press Enter, it doesn't wait for my password (its as if I pressed Enter without entering anything). Even if I enter something, the text shown in plaintext and then it keeps on saying my password is wrong. After few times, the screen is cleared and it prompts for my username again and the same loop goes on. Expectation of the Maximum of iid Gumbel Variables I keep reading in economics journals about a particular result used in random utility models. One version of the result is: if $\epsilon_i \sim_{iid}, $ Gumbel($\mu, 1), \forall i$, then:   $$E[\max_i(\delta_i + \epsilon_i)] = \mu + \gamma + \ln\left(\sum_i \exp\left\{\delta_i \right\} \right),  $$  where $\gamma \approx 0.52277$ is the Euler-Mascheroni constant.  I've checked that this makes sense using R, and it does.  The CDF for the Gumbel$(\mu, 1)$ distribution is:  $$G(\epsilon_i) = \exp(-\exp(-(\epsilon_i - \mu)))$$  I'm trying to find a proof of this and I've had no success.  I've tried to prove it myself but I can't get past a particular step.   Can anyone point me to a proof of this?  If not, maybe I can post my attempted proof up to where I get stuck. java.lang.OutOfMemoryError: PermGen space Exception I'm trying to connect 32 I²C "root of trust"  devices.    I'm thinking about a good way that does that, I mean what kind of communication should I use? A digital multiplexer that selects a device? but based on what? switching on the VDD source? but that needs reinitialization of the device and that takes time. iOS: Compare two dates Why would a single celled organism evolve to be multi-celled? I read a story this week on Richard Lenski who has been 'evolving' E. coli for more than 50,000 generations now.  One comment I read was from someone who doesn't accept Evolution who pointed out that we haven't seen a single celled organism 'evolve' into a multi-celled organism.  Another person responded and said that a bacteria is not going to evolve into something that isn't a bacteria.  So, if Evolution created single celled organisms and then multi-celled organisms how might that change have happened?  And is it possible to recreate that set of driving forces to make a bacteria something other than a bacteria?  To that end, what advantage does being multi-cellular have over being unicellular (if that's even a word)? Will moving blog posts from under an existing category to a new SUBcategory have a negative impact from an SEO POV? Probability to obtain more than X with 3 dice. I am using gedit text editor with embedded terminal in ubuntu 12.04. I'm trying to search for some text using grep. I want to search for this line of code   'type' =&gt; 'select'   I tried:  grep -r '\'type\' =&gt; \'select\''  But grep didn't return any results.  So can someone kindly tell me how to search for the code above? Do I have to use “do” in any “wh-” question? is it possible to create this kind of material with the standard textures? The Voronoi texture (set to cells) is coming close but I don’t know if it is possible to a) set the single cells apart from each other and b) to give them seperate colors. What's a word for someone who is constantly asking for same thing? Hi I'm looking for a word for someone who is constantly asking for something and keeps wanting updates about it. The closest words I can think of is pushy and, to a lesser extent, annoying. But clearly these words don't directly mean what I intend. This might seem like a very simple question, but what is the easiest way to turn a normal vertical list into a horizontal one? I never really bothered to keep my Hotmail contact information up to date, so now that I connected it to Windows 8, suddenly I see all this outdated contact information or people I've long stopped talking to.    I don't see any buttons or options where I can click to delete someone.  So how do I clean up my Windows 8 People app and remove these contacts?