angularjs - how to display popup on the click of submit buttonof a form? -


I have a form and two text fields, on clicking on the form button submit, I want to generate pop ups And display the value put in the text field of the form. ???

You can use the NG-model. Here's an example:

-HTML

  & lt; Div & gt; & Lt; Input type = "text" ng-model = "input1" /> & Lt; Input type = "text" ng-model = "input2" /> & Lt; Ng-click button = "submit text ()" & gt; Submit & lt; / Button & gt; & Lt; / Div & gt;  

- Controller:

  $ scope.submitText = function () {var text1 = $ scope.input1; Var text2 = $ scope.input2; Warning (text1 + "+ + 2 text)"; };  

Comments

Popular posts from this blog

apache - 504 Gateway Time-out The server didn't respond in time. How to fix it? -

c# - .net WebSocket: CloseOutputAsync vs CloseAsync -

c++ - How to properly scale qgroupbox title with stylesheet for high resolution display? -