gpt4 book ai didi

javascript - 非常基本的例子不起作用

转载 作者:行者123 更新时间:2023-12-01 01:55:29 25 4
gpt4 key购买 nike

有人可以解释一下为什么这个简单的例子不起作用吗?

<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.11/angular.min.js"></script>


<p>{{accountID}}</p>

<input class="form-control input-sm" uib-tooltip="Search by Account ID" validator="/^[0-9]{1,15}$/" validator-invoke="watch" validator-error="Account ID must have 1 to 15 digits." type="number" placeholder="Search by Account ID"
ng-model="accountID" min="1" required>

最佳答案

您需要将代码包含在 <div ng-app>...</div> 之间标签如下:-

<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.11/angular.min.js"> 
</script>
<div ng-app>
<p>{{accountID}}</p>
<input class="form-control input-sm" uib-tooltip="Search by Account ID" validator="/^[0-9]{1,15}$/" validator-invoke="watch" validator-error="Account ID must have 1 to 15 digits." type="number" placeholder="Search by Account ID" ng-model="accountID" min="1" required>
</div>

关于javascript - 非常基本的例子不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51080088/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com