Showing
1 changed file
with
5 additions
and
5 deletions
| @@ -38,12 +38,12 @@ class Comment extends Common | @@ -38,12 +38,12 @@ class Comment extends Common | ||
| 38 | $data['enclosure'] = json_encode($data['enclosure']); | 38 | $data['enclosure'] = json_encode($data['enclosure']); |
| 39 | #unset($data['enclosure']); | 39 | #unset($data['enclosure']); |
| 40 | $succ = httpRequest(ON_LINE.'App.User.SetComment', 'post', $data); | 40 | $succ = httpRequest(ON_LINE.'App.User.SetComment', 'post', $data); |
| 41 | - #$succ = json_decode($succ,true); | ||
| 42 | - #if($succ['data']){ | ||
| 43 | - # return $result = ['code'=>1,'msg'=>'评论成功!','data'=>$data,'rel'=>1];# | ||
| 44 | - #}else{ | 41 | + $succ = json_decode($succ,true); |
| 42 | + if($succ['data']){ | ||
| 43 | + return $result = ['code'=>1,'msg'=>'评论成功!','data'=>$data,'rel'=>1];# | ||
| 44 | + }else{ | ||
| 45 | return $result = ['code'=>0,'msg'=>'评论失败!','data'=>$data,'fail'=>$succ];# | 45 | return $result = ['code'=>0,'msg'=>'评论失败!','data'=>$data,'fail'=>$succ];# |
| 46 | - #} | 46 | + } |
| 47 | 47 | ||
| 48 | } | 48 | } |
| 49 | return $this->fetch(); | 49 | return $this->fetch(); |
-
Please register or login to post a comment