However, both ways you have there aren't entirely accurate. If somebody enters a space into your text box, it's no longer empty. The isset function probably wouldn't work as you'd expect, because when the form is submitted, it's still posting the value of the textbox as a variable, and as such it should always be set.
My suggestion:
if(isset($_POST['submit'])) {
// We use trim to clear any spaces from the start and end of a string
if(empty(trim($_POST['username']))) {
echo "Oh god, you silly fool! You forgot your username! What are we to do. . . PANIC!";
die;
}
// Continue processing
} else {
// display your form
}