How do I use JQuery's event handler use a textbox with a submit button? -


I am a new JQuery user and submitting text through a text box and a list of a submit button on the web browser window As an item which adds to the end of an unordered list.

HTML:

  & lt; Ul class = "list" & gt; & Lt; Li & gt; & Lt; / Li & gt; & Lt; / Ul & gt;   

JS:

  var text = $ ('text'); Var submit = $ ('submit');   

Q: Will you use jQuery event handlers to submit text in a text box and submit my text using a HTTP request?

Any advice and coding examples will be appreciated! Thanks!

Create a form, enter all the form fields in it, then share the submit button < Previous> var text a = $ ('. Text'); Var submit = $ ('. Submit'); Submit.click (function () {$ .ajax ({url: 'yourServerURL', type: 'post', data: text.val ()});});

Comments

Popular posts from this blog

excel vba - How to delete Solver(SOLVER.XLAM) code -

github - Teamcity & Git - PR merge builds - anyway to get HEAD commit hash? -

ios - Replace text in UITextView run slowly -