Home  >  Article  >  Backend Development  >  What is the difference between the I() method receiving data and the create() method receiving data in ThinkPHP? ?

What is the difference between the I() method receiving data and the create() method receiving data in ThinkPHP? ?

WBOY
WBOYOriginal
2016-12-01 01:27:44991browse

What is the difference between the I() method receiving data and the create() method receiving data in ThinkPHP? ?

Reply content:

What is the difference between the I() method receiving data and the create() method receiving data in ThinkPHP? ?

The I() method will automatically filter html entities. The create method needs to manually call the filter method of the model after automatic creation. Create includes automatic creation of data objects, automatic verification, automatic completion, and field mapping

The data received by create will be verified in the model, but if it is received directly using the I function, it will not be possible. This is one of the points

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn