return $section_wall_data->setVotedUsers($_POST['post_id'], $_POST['user_id'], $_POST['type_vote']);
if(!empty($error)){
return json_encode(array('result' => 'error', 'msg' => $error));
}else{
return json_encode(array('result' => 'success'));
}
<input type="hidden" name="page-title" style="display:none">
<script>document.querySelector("input[name='page-title']").value = document.title</script>