search

Home  >  Q&A  >  body text

php filter special string

2018-06-26_204346.jpg

How to filter out the white squares in php and js? Before and after entering the database, the screenshots are read directly from the database, and the white squares are displayed in the database. blocks.

捂耳听风。捂耳听风。2382 days ago1364

reply all(5)I'll reply

  • 秋香姐家的小书童

    秋香姐家的小书童2018-06-27 17:26:19

    Replace with empty before inserting

    reply
    0
  • 无忌哥哥

    无忌哥哥2018-06-27 09:04:01

    You have to deal with this when inserting into the database. It may be garbled characters or unrecognizable strings. It depends on what data you insert.

    reply
    0
  • 捂耳听风。

    What is inserted is a string. I am afraid that someone may accidentally generate special symbols. How should I handle it before inserting it into the database?

    捂耳听风。 · 2018-06-27 09:31:22
    捂耳听风。

    What is inserted is a string. I am afraid that someone may accidentally generate special symbols. How should I handle it before inserting it into the database?

    捂耳听风。 · 2018-06-27 09:31:24
    无忌哥哥

    PHP processes form data. It is recommended that Baidu take a look at the documentation.

    无忌哥哥 · 2018-06-27 09:52:54
  • Cancelreply