How to send data via Javascript - Jquery
-
1send data where ? what kind of data ?Poelinca Dorin– Poelinca Dorin2011-01-06 11:47:26 +00:00Commented Jan 6, 2011 at 11:47
-
2from where to where, what is your current code, what is your problem, what have you already tried (I would vote that down but its not even worth wasting my points ....)Hannes– Hannes2011-01-06 11:48:00 +00:00Commented Jan 6, 2011 at 11:48
-
1Hannes, your 1888 reputation cannot compete with Gani's 8... he/she is a member of SO for only 2 days now... we're a community to offer helping hand, not to undermine other's feelings, please consider that when posting commentsZathrus Writer– Zathrus Writer2011-01-06 13:15:41 +00:00Commented Jan 6, 2011 at 13:15
Add a comment
|
3 Answers
If you want to send some data to a server side script your could use AJAX. jQuery has great support through $.ajax(), $.post(), $.get(), $.getJSON():
$.ajax({
url: '/script',
data: { key1: 'value 1', key2: 'value 2' },
success: function(result) {
alert('data successfully sent');
}
});