Ver originalif(isset($_POST['guardar'])){ if($_POST['facebook'] == ''){ echo "Rellena el campo facebook"; } else{ //la consulta }}