I want to add value to the "value" filed of input dynamically but this is not working.
<form action="/assignCol" method="POST">
<input
type="RefCode"
id="RefCode"
name="RefCode"
class="form-control"
value="<%= user[i].id %>"
readonly="readonly"
/>
</form>
my aim is to provide the user with a feature to update the details of a person just by clicking the update button. I want that once the user clicks the update button I could be able to send the user[i].id to the put API.
also, I want to send this user[i].id to the put API in the backend once I click this update button. so that in the backend I can fetch the data of that user with this id using req.body.id and find and edit the details of that user. is there any other possible way to do that?