I have a hidden field with three integer values, example:
I want to use jQuery to remove a giv
Basically the same as @Shaz answer but perhaps a little cleaner. This uses a function that returns the val to use. See the API docs at http://api.jquery.com/val/
$('input').val(function(index, val){
return val.replace('10', '').trim();
});
To handle the possible trailing space after your integer:
val.replace(/10 ?/, '').trim()
<input type="hidden" id="my_input" value = "10 23 42">
<script type="text/javascript">
jQuery(document).ready(function(){
$("my_input").attr("value", $("my_input").attr("value").replace("10 ", ""));
});
</script>
<script>
$("input").val($("input").val().replace("10 ", ""));
</script>