MySQL single quote insertion error

后端 未结 2 1979
鱼传尺愫
鱼传尺愫 2021-01-29 11:30

Ok so I have a form in a made from scratch forum. I am using NBBC to parse BBCode for the forum. Here is the code. My main focus is to transform the single quotes into html enti

相关标签:
2条回答
  • 2021-01-29 11:48

    You need to use mysql-real-escape-string http://php.net/manual/en/function.mysql-real-escape-string.php - not htmlspecialchars

    0 讨论(0)
  • 2021-01-29 11:54

    try mysql_real_escape_string(). should work!

    http://php.net/manual/en/function.mysql-real-escape-string.php

    0 讨论(0)
提交回复
热议问题