PHP 恒量

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-13 12:07:32
Original
924 people have browsed it

PHP 常量

设置 PHP 常量如需设置常量,请使用 define() 函数 - 它使用三个参数:首个参数定义常量的名称第二个参数定义常量的值可选的第三个参数规定常量名是否对大小写敏感。默认是 false。下例创建了一个对大小写敏感的常量,值为 "Welcome to W3School.com.cn!":实例<?phpdefine("GREETING", "Welcome to W3School.com.cn!");echo GREETING;?>运行实例下例创建了一个对大小写不敏感的常量,值为 "Welcome to W3School.com.cn!":实例<?phpdefine("GREETING", "Welcome to W3School.com.cn!", true);echo greeting;?>
Copy after login

Related labels:
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
Latest Issues
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template