|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2004-12-26 11:32 UTC] derick@php.net
[2004-12-27 00:57 UTC] aitrus at tresgeek dot net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 23 00:00:01 2025 UTC |
Description: ------------ I thought that this used to be the behavior of empty()... It would be nice of empty() returned true when passed a string which only had spaces, tabs, or newline characters in it. Reproduce code: --------------- $foo = ' '; if ( empty( $foo ) ) { echo "foo is empty"; } else { echo "foo is NOT empty"; }//if --- output is: 'foo is NOT empty' Expected result: ---------------- expected output: 'foo is empty'