How to get value for a input button using jquery?
Like any other input, to get the value of a button use .val():
$('input:button').click(function() {
alert($(this).val());
});
http://jsfiddle.net/3QDM5/
I'm not sure exactly what you're trying to do with your script though!
use attr http://api.jquery.com/attr/
$(document).ready(function() {
$('#button1').click(function() {
var text = $(this).attr('value');
$("#input").val(text);
});
});