Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
define() - Defining Constants
How do you define a constant in PHP?
✍: FYIcenter
You can define a constant by using the define() function. Once a constant is defined, it can never be changed or undefined. For example:
<?php
define("CONSTANT", "Hello world.");
echo CONSTANT; // outputs "Hello world."
echo Constant; // outputs "Constant" and issues a
notice.
?>
Only scalar data (boolean, integer, float and string) can be contained in constants.
2007-02-27, 6205👍, 0💬
Popular Posts:
How To Truncate an Array? - PHP Script Tips - PHP Built-in Functions for Arrays If you want to remov...
Explain in detail the fundamental of connection pooling? When a connection is opened first time a co...
From performance point of view how do they rate ? Repeater is fastest followed by Datalist and final...
Can include files be nested? The answer is yes. Include files can be nested any number of times. As ...
What is V model in testing? V model map’s the type of test to the stage of development in a project....