Re: isset
| From: | Jim Lucas | Date: | Mon, 16 Apr 2007 14:50:55 +0000 |
| Subject: | Re: isset | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-253008@lists.php.net to get a copy of this message | ||
Richard Kurth wrote:
What do you do when isset does not work? If I send data in a $_REQUEST['var'] like if (isset($_REQUEST['var'])) { } Put var has no data it still says it is set. Because $_REQUEST['var'] = "" and isset thinks "" is set I use this combination a lot:if ( isset($_GET['something']) && !empty($_GET['something']) ) { // do something here with $_GET['something'] } -- Enjoy, Jim Lucas Different eyes see different things. Different hearts beat on different strings. But there are times for you and me when all such things agree. - Rush