JQuery Post call return a server 500 error

I can't make to work a Jquery post call in my new server. I was testing send a post call when I close a Jquery Ui dialog, which [send a sms trough Twilio interface][1]. It's working in my old server but when I installed it in my new server it doesn't work, I don't know why. THis is the button who sent the post call: $( "#dialog1" ).dialog({ autoOpen: false, width:240, height:250, modal:true, show: "blind", hide: "fade", buttons: { Ok: function() { $( this ).dialog( "close" ); $.post("tmpl/do/sms.php", { cantidad : $("#test").val() }); } } }).css("font-size", "16px"); And this is the PHP which receive that call: account->sms_messages->create( 'xxxxx, // From '+xxxxx', // To 'yyyyy' // SMS ); } catch (Exception $e) { echo 'Error sending sms: ' . $e->getMessage(); } ?> If I press the button in the dialog it send a error 500 in the console. If someone has any idea, I'll be really thankful [1]: https://www.twilio.com/docs/api/rest/sending-messages

以上就是JQuery Post call return a server 500 error的详细内容,更多请关注web前端其它相关文章!

赞(0) 打赏
未经允许不得转载:web前端首页 » jQuery 答疑

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

前端开发相关广告投放 更专业 更精准