Is there a way to send div data in form method=post
?
Below is the Ravel code.
I would like to send divid="tetsuya"
, is there a good way?
Do I have no choice but to use hidden and insert it?
<form method="post" action={{route('output')}}>
@csrf
<input type="text" id="komuro" name="kei" value="">
<divid="tetsuya">63</div>
</form>
The formdata
event is simple.
form.addEventListener('formdata'e=>{
e.formData.append('mitsuko', document.querySelector('#tetsuya').textContent);
});
© 2024 OneMinuteCode. All rights reserved.