Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with "<form>": describe running javascript on submit: onsubmit and javascript pseudo-protocol #7142

Closed
jxu opened this issue Jul 21, 2021 · 3 comments
Labels
closed: wontfix Out of scope, too much effort, or working as intended Content:HTML Hypertext Markup Language docs

Comments

@jxu
Copy link
Contributor

jxu commented Jul 21, 2021

MDN URL: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/form

What information was incorrect, unhelpful, or incomplete?

I have been reading Stack Overflow for solutions to have a form run run javascript without refreshing the page. This is achieved by returning a javascript function in onsubmit, then the javascript function has to return false? https://stackoverflow.com/a/16262814

Also there is a method to do action="javascript:function()" that probably should be documented.

There is also the solutions here https://stackoverflow.com/questions/12694984/make-form-run-a-javascript-function?noredirect=1&lq=1

Specific section or headline?

Attributes?

MDN Content page report details
@jxu jxu changed the title Issue with "<form>": describe onsubmit and javascript pseudo-protocol Issue with "<form>": describe running javascript on submit: onsubmit and javascript pseudo-protocol Jul 21, 2021
@sideshowbarker sideshowbarker added Content:HTML Hypertext Markup Language docs help wanted If you know something about this topic, we would love your help! labels Jul 22, 2021
@NegiAkash890
Copy link
Contributor

NegiAkash890 commented Jul 28, 2021

Hi, I see action documented under this section . Can you please explain the issue you are facing ?

@jxu
Copy link
Contributor Author

jxu commented Jul 28, 2021

Document onaction and link to javascript: url #7143

@Rumyra Rumyra added the needs triage Triage needed by staff and/or partners. Automatically applied when an issue is opened. label Nov 25, 2021
@sideshowbarker sideshowbarker removed the needs triage Triage needed by staff and/or partners. Automatically applied when an issue is opened. label Jul 6, 2022
@Josh-Cena
Copy link
Member

Hello,

So I think this should not be documented as part of this page as it's more a general engineering concept than something specific to how forms work.

@Josh-Cena Josh-Cena closed this as not planned Won't fix, can't repro, duplicate, stale Jun 19, 2024
@Josh-Cena Josh-Cena added closed: wontfix Out of scope, too much effort, or working as intended and removed help wanted If you know something about this topic, we would love your help! labels Jun 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed: wontfix Out of scope, too much effort, or working as intended Content:HTML Hypertext Markup Language docs
Projects
None yet
Development

No branches or pull requests

5 participants