jsfiddle error {“error”: “Please use POST request”} when submitting a form

瘦欲@ 提交于 2020-01-22 17:03:30

问题


I'm new to using JSfiddle and get this error: {"error": "Please use POST request"} everytime I submit the form. What I have understood, you cannot submit a post request in JSfiddle, so how I can append something to a form?

<form>
  <label>Add</label>
  <input type="text"/>
</form>  

$('form').on("submit", function(){
  $('form').after("apple")
});

回答1:


If you do not explicitly set a form method browsers will default to using GET.

<form method="POST">


来源:https://stackoverflow.com/questions/24420736/jsfiddle-error-error-please-use-post-request-when-submitting-a-form

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!