Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
mysqli_real_escape_string を使用して投稿データを消去します。また、SQL LIKE 句で使用される変数に addcslashes() を適用する必要がありますか?
[準備されたステートメントを使用すると、おそらくこの議論が無効になることを理解しています。]
準備済みステートメントを使用できない場合 (常に良いオプションです) - 私が知る限り、ワイルドカードのように mysql をエスケープするのが最善です:
addcslashes($param, '%_');