ajax jsonでデータを1行で投稿すると
<p>test</p>
すべて問題ありませんが、データを2行で投稿すると:
<p>test</p>
<p>test</p>
エラー403が発生しました
FireBug を使用すると、次の情報が表示されます。
2 行の場合: sastojci=%3Cp%3Efasdfasd%3C%2Fp%3E%0A%3Cp%3Efasdfasd%3C%2Fp%3E
これは json のコードです: // #sastojci は textarea です
$('#update').submit(function(){
$sastojci = $('#sastojci').val();
$.ajax({
type: "POST",
dataType: "json",
data: { sastojci : $sastojci},
url: 'updatedata.php',
success: function(data) {
alert(data.poruka);
},
error: function (data, textStatus, jqXHR) {
alert(data.status);
}
});
return false;
});
これは私の質問の更新です:
テキストエリアの入力を使用すると、エラーは再び403になります
私が投稿した場合:
<p>test</p>p>test</p>
何でもOKです。
私が投稿した場合:
<p>test</p><p>test</p>
error is 403 forbiden : このサーバーの updatedata.php にアクセスする権限がありません。
唯一の違いは「<」です??? ここで何が起こっているのかわかりません!!!