如题,HTML代码如下:
- <script language="JavaScript" type="text/javascript">
- function fu() {
- var a ={{ articles.title }};
- $.ajax({
- type: "post",
- url: "/test",
- contentType: "application/json; charset=UTF-8",
- data: JSON.stringify(a),
- success: function(data),
- error: function(xhr, type) {
- }
- });
- }
- </script>
请问后台应该怎样写才能接收到前台传递的数据呢?