diff options
| author | James Wagoner | 2014-02-10 00:17:08 -0800 | 
|---|---|---|
| committer | Caitlin Potter | 2014-02-10 19:35:22 -0500 | 
| commit | a68624444afcb9e3796b1a751cf3817cafd20240 (patch) | |
| tree | 241f842c1d4fa97489707dd8d23dd7134318a274 | |
| parent | 945fc1a4bca1a0856fc909f1d1b8d60d4a5e59bb (diff) | |
| download | angular.js-a68624444afcb9e3796b1a751cf3817cafd20240.tar.bz2 | |
docs(ngSubmit): ngSubmit also works with the `data-action`/`x-action` attributes
The documentation states only the "action" attribute triggers this, which is incorrect. When using
the attribute "data-action" (as for AJAX control, attempting to bypass the "action" attribute but
still make it obvious what its for), Angular thinks this is also classified as "action" and
continues with the page submission.
Closes #6196
| -rw-r--r-- | src/ng/directive/ngEventDirs.js | 4 | 
1 files changed, 2 insertions, 2 deletions
| diff --git a/src/ng/directive/ngEventDirs.js b/src/ng/directive/ngEventDirs.js index f63d3ca1..45b2d404 100644 --- a/src/ng/directive/ngEventDirs.js +++ b/src/ng/directive/ngEventDirs.js @@ -298,8 +298,8 @@ forEach(   * Enables binding angular expressions to onsubmit events.   *   * Additionally it prevents the default action (which for form means sending the request to the - * server and reloading the current page) **but only if the form does not contain an `action` - * attribute**. + * server and reloading the current page), but only if the form does not contain `action`, + * `data-action`, or `x-action` attributes.   *   * @element form   * @priority 0 | 
