ajax - jQuery send string as POST parameters -


i want send string ajax post parameter.

the following code:

$.ajax({    type: "post",    url: "http://nakolesah.ru/",    data: 'foo=bar&ca$libri=no$libri',    success: function(msg){      alert('wow'+msg);    } }); 

is not working. why?

try this:

$.ajax({     type: 'post',     // make sure respect same origin policy url:     // http://en.wikipedia.org/wiki/same_origin_policy     url: 'http://nakolesah.ru/',     data: {          'foo': 'bar',          'ca$libri': 'no$libri' // <-- $ sign in parameter name seems unusual, avoid     },     success: function(msg){         alert('wow' + msg);     } }); 

Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -