转义处理
This commit is contained in:
parent
48dff94570
commit
09dea89ba5
@ -31,7 +31,7 @@ if ($act == 'newevent') {
|
|||||||
} else if ($act == 'edityunying') {
|
} else if ($act == 'edityunying') {
|
||||||
$id = r('id');
|
$id = r('id');
|
||||||
$dict = array(
|
$dict = array(
|
||||||
'yunying_remark' => r('content')
|
'yunying_remark' => stripslashes(r('content'))
|
||||||
);
|
);
|
||||||
|
|
||||||
$sql = DB::update('calendar', $dict, "id='{$id}'");
|
$sql = DB::update('calendar', $dict, "id='{$id}'");
|
||||||
@ -40,7 +40,7 @@ if ($act == 'newevent') {
|
|||||||
} else if ($act == 'edityanfa') {
|
} else if ($act == 'edityanfa') {
|
||||||
$id = r('id');
|
$id = r('id');
|
||||||
$dict = array(
|
$dict = array(
|
||||||
'yanfa_remark' => r('content')
|
'yanfa_remark' => stripslashes(r('content'))
|
||||||
);
|
);
|
||||||
|
|
||||||
$sql = DB::update('calendar', $dict, "id='{$id}'");
|
$sql = DB::update('calendar', $dict, "id='{$id}'");
|
||||||
@ -49,7 +49,7 @@ if ($act == 'newevent') {
|
|||||||
} else if ($act == 'editchanpin') {
|
} else if ($act == 'editchanpin') {
|
||||||
$id = r('id');
|
$id = r('id');
|
||||||
$dict = array(
|
$dict = array(
|
||||||
'chanpin_remark' => r('content')
|
'chanpin_remark' => stripslashes(r('content'))
|
||||||
);
|
);
|
||||||
|
|
||||||
$sql = DB::update('calendar', $dict, "id='{$id}'");
|
$sql = DB::update('calendar', $dict, "id='{$id}'");
|
||||||
@ -785,7 +785,7 @@ if ($act == 'newevent') {
|
|||||||
arr = JSON.stringify(arr)
|
arr = JSON.stringify(arr)
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: './?app=pmcalendar&act=editchanpin',
|
url: './?app=pmcalendar&act=editchanpin',
|
||||||
dataType: 'json',
|
dataType: 'application/x-www-form-urlencoded',
|
||||||
type:"post",
|
type:"post",
|
||||||
async:"true",
|
async:"true",
|
||||||
data: {
|
data: {
|
||||||
@ -1325,6 +1325,7 @@ if ($act == 'newevent') {
|
|||||||
success: function (res) {
|
success: function (res) {
|
||||||
$('#pop-title').html('【'+ res.game +'】'+ res.event + ':' + res.title );
|
$('#pop-title').html('【'+ res.game +'】'+ res.event + ':' + res.title );
|
||||||
// $("#cptext").val(res.yanfa_remark)
|
// $("#cptext").val(res.yanfa_remark)
|
||||||
|
// res.chanpin_remark = res.chanpin_remark.replace('\\','')
|
||||||
console.log(res.chanpin_remark)
|
console.log(res.chanpin_remark)
|
||||||
var chanpin_remark =JSON.parse(res.chanpin_remark)
|
var chanpin_remark =JSON.parse(res.chanpin_remark)
|
||||||
var yunying_remark = JSON.parse(res.yunying_remark);
|
var yunying_remark = JSON.parse(res.yunying_remark);
|
||||||
|
Loading…
Reference in New Issue
Block a user