Reply to RE: [PHP] Someone please help me with this PHP script.

Your name:

Reply:


Posted by "Oli Howson" on 12/18/05 17:56

The ? And : are a shortcut for ifelse, that could also be written

If (isset($_GET['page'])
{
$page = $_GET['page'];
}
else
{
$page = null;
}

The shortcut is a lot quicker to write (if you understand it) but not as
readable.

isset just returns true if a variable has been set, false if not :)

hth

-----Original Message-----
From: Erik Johnson [mailto:budduh@gmail.com]
Sent: 18 December 2005 15:42
To: php-general@lists.php.net
Subject: Re: [PHP] Someone please help me with this PHP script.

I was wondering.. how exactly does the isset function work? I saw that
Robert Cummings wrote:

$page = isset( $_GET['page'] ) ? $_GET['page'] : null;

What exactly does that mean?

[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

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