The submit button in angular is clicked. Then, hide the prompt text and show? ?
闭关修行中......
What the questioner wants to ask is how to replace the text in the button? Bind a click event to the button to change a variable that identifies the state, and then determine what content is displayed through the variable.
Define a variable to control and change the value of your variable in the submit event, for examplehtml
<button ng-click="submitFunc()" ng-show="btnShow" style="display:none;">提交前</button> <button ng-hide="btnShow" style="display:none;">提交后</button> <p ng-hide="btnShow" style="display:none;">提交后显示的文字</p>
js
$scope.btnShow=true; $scope.submitFunc=function(){ $scope.btnShow=fasle; //以下是你点击提交的其他代码 }
What the questioner wants to ask is how to replace the text in the button? Bind a click event to the button to change a variable that identifies the state, and then determine what content is displayed through the variable.
Define a variable to control and change the value of your variable in the submit event, for example
html
js