开发者

ajax() function when it include in a mysql_

I modify a php comment system. I want add it after every article witch are query 开发者_开发知识库from database.


The "data" property of a $.ajax request is actually a json object. jQuery deals with serializing and getting the data to the server automatically.

You want to do: data: { title: title, content: content }

On the PHP end: $title = $_POST['title'] $content = $_POST['content']

http://php.net/manual/en/reserved.variables.post.php

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜