jsp - Copy my addresses in different fields in javascript -


I have different addresses in my jsp, I can choose to copy in my fields. I wanted to know that to provide me a sample code in javascript, thanks.

A list of various editable field addresses, when I select an address, I will automatically notify my fields

  • To begin, you must provide an element of HTML elements of interest:

       

    You can get a specific element by using:

      var addressElement = document.getElementById ('address'); Var other address element = document.getElementById ('other address');  

    You can get values ​​by the value attribute:

      var addressValue = addressElement.value;  

    You can set a value with the same attribute:

      otherAddressElement.value = addressValue;  

    Comments

    Popular posts from this blog

    Eclipse CDT variable colors in editor -

    AJAX doesn't send POST query -

    wpf - Custom Message Box Advice -