I have a form where I send a query to the current url, via parameters GET
. For example, I have url/teste
, when sending the query through this form, it will be url/teste?term=minha+consulta
.
I did not use Angular
in this part because it was ready, so the form already existed before.
When I put the angle, this form stopped submitting.
Exemplifying my scenario:
<body ng-app="my_app">
<!-- esse input manda para mesma página uma pesquisa GET, por isso não usei "ACTION" -->
<form id="form-pesquisa">
<input type="search" name="term" />
<button type='submit'>Pesquisar</button>
</form>
<!-- uso esse formulário no Angular -->
<form ng-controller="UserCreateController">
<input type='text' name="email" ng-model="user.email" />
<input type='password' name="password" ng-model="user.password" />
</form>
</body>
I noticed that the angle is adding the ng-submitted
classes to this form when I submit the submission.
I would like to know how I can use a form, within the context of ng-app
, but can make a submission via GET
.
Does the angle really block these requests? How to get around this?