How to use native js
to automatically fill the data in the previous two rows to the third row after calculation? Thanks!
三叔2017-06-26 10:52:03
If it is angular
or react
, newer front-end frameworks support two-way binding
;
If it is jquery
or native js
, then you can only operate dom
node binding events;
阿神2017-06-26 10:52:03
For frameworks, ng or vue, you only need to bind a value to the above two, and the third one is equal to the sum of the first two!
If it is native js or jquery, bind blur or change events to the first and second text boxes! When the event is triggered, the values of the first two text boxes are calculated and assigned to the third one!