note 93608 added to function.define
| From: | mailbrent at gmail dot com | Date: | Fri, 18 Sep 2009 05:52:35 +0000 |
| Subject: | note 93608 added to function.define | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-160816@lists.php.net to get a copy of this message | ||
It is worthy noting that define() does not except the tab character between parameters. It can only
be spaces or no character at all..
Incorrect:
define('MY_CONSTANT', "value");
Correct
define('MY_CONSTANT', "value");
Correct
define('MY_CONSTANT',"value");
It took me a while to figure out while my constants were not working. Other built in functions like
array allow you to tab out your parameters which some programmers do in order to make the code look
tidy. Don't try it with define()
----
Server IP: 209.41.74.194
Probable Submitter: 97.103.130.14
----
Manual Page -- http://www.php.net/manual/en/function.define.php
Edit -- https://master.php.net/note/edit/93608
Del: integrated -- https://master.php.net/note/delete/93608/integrated
Del: useless -- https://master.php.net/note/delete/93608/useless
Del: bad code -- https://master.php.net/note/delete/93608/bad+code
Del: spam -- https://master.php.net/note/delete/93608/spam
Del: non-english -- https://master.php.net/note/delete/93608/non-english
Del: in docs -- https://master.php.net/note/delete/93608/in+docs
Del: other reasons-- https://master.php.net/note/delete/93608
Reject -- https://master.php.net/note/reject/93608
Search -- https://master.php.net/manage/user-notes.php