Reply to Re: My mind is going? empty($_SESSION["not_there"])

Your name:

Reply:


Posted by Jan Pieter Kunst on 12/19/05 19:26

In article <epspf.4827$It6.4454@fe02.lga>, Bob Stearns
<rstearns1241@charter.net> wrote:

> I thought that the given expression was always TRUE if "not_there"
> wasn't among the keys (or subscripts if you will) of $_SESSION.

I would always use:

if (isset($_SESSION['not_there'])) {

}

or

if (array_key_exists('not_there', $_SESSION)) {

}

in your case.

Try if that works better. I only use empty($var) when I am certain that
$var exists. (Note: I didn't follow your code step by step, so this may
be useless advice.)

JP

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация