Forms in AMP can be submitted as full page GET requests, or as XHR (or AJAX) GET or POST requests:
- If you use method="GET" in your form, you must then define a submission endpoint in either the action or action-xhr attribute
- If you use method="POST" then you must only use action-xhr for your submission endpoint
- Endpoints must be served on an HTTPS URL, and must not link to the AMP cache CDN
- Finally, you must also include the target attribute, and it can have a value of either _blank (opens in new window) or _top (opens in current window)
The following inputs are not permitted: <input type=button>, <input type=file>, <input type=image>, and <input type=password>.