There are three conversion methods for PHP Data types: 1. add the target type enclosed in brackets before the variable to be converted. 2. use three conversion functions of specific types: intval () and floatval (), strval () 3 use the general type conversion function settype (mixedvar, stringtype) The first conversion PHP Data type has three conversion methods: 1. add the target type enclosed in parentheses before the variable to be converted. 2. use three types of conversion functions: intval (), floatval (), strval () 3. use the settype (mixed var, string type) Common type conversion function. The first conversion method is (int) (bool) (float) (string) (array) (object). example: [php] Second conversion method: intval () floatval () strval () example: [php] Third conversion method: settype (); example: [php]
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service