i assume you mean "ternary". anyway, here's the basic idea...
this:
$loginUsername = (get_magic_quotes_gpc()) ? $loginUsername : addslashes($loginUsername);
is exactly the same as this:
if (get_magic_quotes_gpc())
{
$loginUsername = $loginUsername;
}
else
{
$loginUsername = addslashes($loginUsername);
}