those are valid ways of doing it, however, they both will likely create a log of the check, since it is such an ambiguous check, you can do it like
if ($_POST['varname'] == "")
that will not create an error log...
but really it is more of a personal preference than anything