Home > PHP Framework > ThinkPHP > body text

Solve the problem of A non well formed numeric value encountered in TP5.1

藏色散人
Release: 2021-04-27 08:54:59
forward
2722 people have browsed it

The following tutorial column will introduce to you how to solve the problem of A non well formed numeric value encountered in TP5.1. I hope it will be helpful to friends in need!

A non well formed numeric value encountered problem occurred in TP5.1

Solve the problem of A non well formed numeric value encountered in TP5.1

Blog description

The information involved in the article comes from the Internet and personal summary. It is intended to summarize personal learning and experience. If there is any infringement, please contact me to delete it. Thank you! Problem introduction

A non well formed numeric value encountered

Such a problem is caused by the failure of tp5.1 to automatically convert the time formatFor example, the fields in the database are in varchar format, and the code is written in tp5.1. The field is automatically converted into the timestamp format, and an error will occur.

Problem Solution

Use time fields in the database, or use int type, or not use the automatic conversion of tp5.1

Related recommendations:
Latest 10 thinkphp video tutorial

The above is the detailed content of Solve the problem of A non well formed numeric value encountered in TP5.1. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:segmentfault.com
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template