In the application, a user can register as an initial user of a subsequent user. When the user clicks yes or no to Firm already registered?, if yes, the script changes the form name and id to subUserForm and if they select no, initialUserForm, like so:  &lt;span&gt;Firm already registered?&lt;/span&gt; &lt;label&gt;Yes&lt;input type="radio" name="typeRegister" id="subRegister"&gt;&lt;/label&gt; &lt;label&gt;No&lt;inputtype="radio" name="typeRegister" id="initalRegister"&gt;&lt;/label&gt;   And my submit button  &lt;button class="btn btn--reg bg-phase-green pill-radius txt-white font-body font-weight-medium" type="submit" id="register" disabled&gt;Register&lt;/button&gt;     ('#subRegister').change(function(){    if(this.checked) {      $('#registerForm').attr('name', 'subUserForm').attr('id', 'subUserForm');    } else {      $('#registerForm').attr('name', 'initialUserForm').attr('id', 'initialUserForm');    } })  $('#initalRegister').change(function(){   if(this.checked) {     $('#registerForm').attr('name', 'initialUserForm').attr('id', 'initialUserForm');     } else {       $('#registerForm').attr('name', 'subUserForm').attr('id', 'subUserForm');     } })   The reason is, depending on the option they select, it changes the request made. I've checked that the name and id are being updated, and they are, but when I click submit, nothing happens. Nothing I logged, no request is made etc.  $('#initialUserForm').submit(function(e){     console.log('initial');     e.preventDefault();     var dataString = JSON.parse(JSON.stringify($('#initialUserForm').serializeArray()));     $.ajax({         type: 'POST',         url: 'http://localhost:8080/p3sweb/register/rest-user/',         data: dataString,         contentType: "application/json",         success: function(response) {             console.log(response);         },         error:function(errResponse) {             console.log('fail')         }     }) })  $('#subUserForm').submit(function(e){     console.log('sub');     e.preventDefault();     var dataString = JSON.parse(JSON.stringify($('#subUserForm').serializeArray()));     $.ajax({         type: 'POST',         url: 'http://localhost:8080/p3sweb/register/rest-subsequent-user-step2/',         data: dataString,         contentType: "application/json",         success: function(response) {             console.log(response);         },         error:function(errResponse) {             console.log('fail')         }     }) })   Question  Is there an issue with dynamically changing the name of a form, or am I missing something really simple to why the form data isn't being submitted?
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.
If I've decided to update my SE avatar (in any of the various ways well described in the answer to this ), am I able to return to either the original stock image or previous avatar images I have used? Replacing ArcPy with ArcGIS API for Python? Today I found out about the . I was wondering if you could use this to (eventually) replace ArcPy?  Recently I have been doing analyses that require cloud based solutions. When using AWS, Docker and Jupyter it is very convenient to stick with a Unix based OS such as Ubuntu. However, the Unix alternatives for ArcGIS have their own limitations as well such as the always hard to install python bindings for the  GDAL library. ArcGIS for Python operates cross platform.  Perhaps there are the things I should and should not expect from the ArcGIS API for Python.  Perhaps Arcpy is going to disappear altogether. Is there a way to enter the default keyring password using the command line?   For instance:  You have a remote setup of Ubuntu 10.10 thats set to auto login. You don't want to remove  the keyring password.  All right the system boots up and logs in automatically, then asks for the keyring password now at this point you can create ssh connections but you can't remote desktop.   What can you do to enter the keyring password at this point?  Also, to better clarify, this is from a remote connection using the command line. Properties vs Methods Quick question: When do you decide to use properties (in C#) and when do you decide to use methods?  We are busy having this debate and have found some areas where it is debatable whether we should use a property or a method. One example is this:  public void SetLabel(string text) {     Label.Text = text; }   In the example, Label is a control on a ASPX page. Is there a principle that can govern the decision (in this case) whether to make this a method or a property.  I'll accept the answer that is most general and comprehensive, but that also touches on the example that I have given. How do I detect a click outside an element? I have some HTML menus, which I show completely when a user clicks on the head of these menus. I would like to hide these elements when the user clicks outside the menus' area.  Is something like this possible with jQuery?  $("#menuscontainer").clickOutsideThisElement(function() {     // Hide the menus }); When I boot Ubuntu 10.04.3 from a live CD, it asks me to enter a username and password. I have not booted before, and I haven't created an account. Is there an easier or more 'correct' way to open gedit as root? I have ubuntu 12.04 running in a virtual machine on virtual box.  Its existence is mainly as a 'toy' to play about with Ubuntu, so for this reason I wanted the GUI (is that what 'Dash' is in ubuntu 12.04?  Anyway...)  One thing I am currently using this machine for is a LAMP server.     I use 'gedit' to edit my files, but because I haven't correctly set permissions yet I just open it with sudo in terminal.  Just now, to try to simplify this process I created a shell script on the desktop with a very simple job - sudo gedit  I can't help thinking there must be an even more obvious way to open gedit as root from the GUI than this.  So is there?  Edit:  I just 'improved' my script by replacing sudo with gksudo.  Now I don't have to have a terminal window open while gedit is open.   So I guess this is quite convenient for now :)   It would be good, for the sake of knowledge, to know if this is anything close to how the more seasoned ubuntu users would do this type of thing. biblatex: \parencite in note field prints spurious ; with authoryear-icomp style Prove inequality $n<3^n$ using mathematical induction Prove that $n&lt;3^n$ where $n \in \mathbb N$,  when $ n=1 $, I have proved it's true. And assumed when $n = p$ , $p&lt;3^p$ is true. Can any body help me in showing that it is true for $n =p+1$ How to Execute ShortCut From Command line in Windows 7 We came with a scenario where we have to use Shortcut file (.lnk), which is on the desktop, to execute an application for a headless device (i.e, without manual intervention).  Is there any way to execute it from Command prompt? Why is this series of square root of twos equal $\pi$? Wikipedia claims this but only cites an offline proof:  $$\lim_{n\to\infty} 2^n \sqrt{2-\sqrt{2+\cdots+ \sqrt 2}} = \pi$$  for $n$ square roots and one minus sign. The formula is not the "usual" one, like Taylor series or something like that, so I can't easily prove it. I wrote a little script to calculate it and it's clearly visible, but that's not a proof. Prove that the sum of digits of $(999...9)^{3}$ (cube of integer with $n$ digits $9$) is $18n$ Someone had posted a question on this site as to what would be sum of digits of $999999999999^3$ (twelve $9s$ ) equal to?   I did some computation and found the pattern that sum of digits of  $9^3 = 18$,  $99^3 = 36$,  $999^3 = 54$ and so on. So, I had replied that sum of digits of  $999999999999^3 = 12 \cdot 18 = 216$.  Can anybody help me prove this, that sum of digits of  $(\underbrace{999\dots9}_{n\text{ times}})^3 = 18n.$ When conducting multiple regression, when should you center your predictor variables & when should you standardize them? Can an infectious diseases come from a plant? Coronavirus, HIV, 1918 Flu, etc. They all come from animals. Do any infectious diseases (in humans) come from plants? More specifically, are there viruses that infect plants that can mutate to infect humans? We can prove that there is no integer $n&gt;1$ such that $2^n-1\mid 3^n-1$. This leads to the following question:     Is it true that for every pair of primes $p&lt;q$ there are only finitely many integers $n$ such that $p^n-1\mid q^n-1$? Are there two primes $p&lt;q$ and an integer $n&gt;p+q$ such that $p^n-1\mid q^n-1$?Is it true that if $n&gt;6$ then $2^n-1\nmid 5^n-1$?   Edit: Here are some examples: \begin{array}{ll} 2^{36}-1\mid 41^{36}-1, &amp;3^{12}-1\mid 97^{12}-1,\\ 5^{6}-1\mid 37^{6}-1, &amp;7^{4}-1\mid 151^{4}-1. \end{array}  Now I prove there is no integer $n&gt;1$ such that $2^n-1\mid 3^n-1.$  Proof: Denote $A=2^n-1$ and $B=3^n-1$. If $n$ is even then $3$ divides $A$ but not $B$, a contradiction.  If $n$ is odd then $A\equiv -5\pmod {12}$. Since every prime greater than $3$ is $\equiv \pm1,\pm5 \pmod {12}$, some prime factor $p$ of $A$ must be congruent to $\pm5 \pmod {12}$. As $p \mid B$, we have $3^{n+1}\equiv 3 \pmod p$. Since $n+1$ is even, we get $(\frac{3}{p})=1$, a contradiction again. Schengen visa category required for job interview mysql database no space available I am working on a print for my wall and I am trying to create something like this:      I have already created the letters in Illustrator and now I am adding the colors in Illustrator and then exporting everything to Photoshop and then using the liquify tool to blend the colors to create a similar effect. I also used the healing patch tool to blend in the hard edges.  Is that the right way of doing it? Or is there another way? I would very much like that the the appendix sections of the Table of Contents doesn't have a section numbers, dots, and page numbers. If I do the following  \documentclass{article} \usepackage{tocloft} \addtocontents{toc}{\cftpagenumbersoff{section}} \renewcommand{\cftdot}{} \begin{document} \tableofcontents \newpage \section{Appendix} \section*{Another Letter} \addcontentsline{toc}{section}{Another Letter} \end{document}   then the section "Another Letter" is left aligned, so it doesn't look like the  others.  Question  Is it possible to have "Another Letter" styled the same way as normal TOC entries, but just without section number, dots, and page number? How do I know if I have a selected keyframe using python?