jquery - Form data value from view - Javascript -




i'm trying append data form data view, returns undefined code:

html:

<input type="text" id="iditem">

<button id="idbtn" type="button" onclick="mymethod()">aceptar</button>

javascript:

function mymethod(){     var formdata = new formdata()     formdata.append("nombre",$('#iditem').value) //input-text } 

any suggest?

thanks.

try change $('#iditem').value => $('#iditem').val()





wiki

Comments

Popular posts from this blog

Asterisk AGI Python Script to Dialplan does not work -

python - Read npy file directly from S3 StreamingBody -

kotlin - Out-projected type in generic interface prohibits the use of metod with generic parameter -