PHP Undefined Array Key Handling

<?php
if (isset($_POST['uname'])) {
  $a = isset($_POST['uname'];
}
else
$a = null;
?>

Or

<?php 
$a =  isset($_POST['uname']) ? $_POST['uname'] : null;
?>
Customizable Disclaimer Section: Lorem Ipsum has been the industry’s standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.

Leave a Reply

Your email address will not be published. Required fields are marked *