top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

How to populate/save selected values from drop down values in database using AngularJS, Javascript and MongoDB.?

0 votes
947 views
How to populate/save selected values from drop down values in database using AngularJS, Javascript and MongoDB.?
posted Jan 23, 2017 by anonymous

Looking for an answer?  Promote on:
Facebook Share Button Twitter Share Button LinkedIn Share Button

Similar Questions
+2 votes

I am Getting may JSON array . But i can't know how to fill dropdown list with this array ...

<script>
  function Customer_Id()  
  {  
      var Cus_id = document.getElementById("customer").value;  
      alert(Cus_id);
      var xhr;  
      if (window.XMLHttpRequest) // Mozilla, Safari, ... 
       {   
            xhr = new XMLHttpRequest();  
       }  
        else if (window.ActiveXObject) // IE 8 and older 
        {   
            xhr = new ActiveXObject("Microsoft.XMLHTTP");  
        }  
          var data = "Customer_ID=" + Cus_id;  

             xhr.open("POST", "Volumne_WebUser.php", true);   
             xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");                    
             xhr.send(data);
              xhr.onreadystatechange = display_data;  
      function display_data() {  
     if (xhr.readyState == 4) {  
      if (xhr.status == 200) {  
      var response = xhr.responseText;
      var obj = JSON.parse(response);
      alert(obj['Name']);     
      } else {  
        alert('There was a problem with the request.');          
      }  
     }  
    }  
  }
</script>
+5 votes

I Know that we can always fetch from one database server and rewrite it to another. But what is the simplest way to do this?

...