我想將文本區域用于聊天輸入框,因為它可以調整大小,因為我想要一些預填充的文本,比如
HI Jhon,
Thanks for contacting us....
我想在 textarea 中的文本后給出新行。我的代碼-
$scope.message = "Hi " $scope.firstName ",Thanks for contacting us....... ";
我試過,使用中斷標簽,但沒有用
<textarea id="typeMessageBox" placeholder="Write here..." type="text submit" ng-model="message"></textarea>
我怎樣才能做到這一點 ?
uj5u.com熱心網友回復:
使用 \n 代替 break 標簽。
例如: $scope.message = "Hi " $scope.firstName ",\n 感謝您聯系我們....... ";
轉載請註明出處,本文鏈接:https://www.uj5u.com/net/312559.html
