<?php
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
    if (isset($_POST['name']) and isset($_POST['phone']) and isset($_POST['meli'])) {
        if (!empty($_POST['name']) and !empty($_POST['email']) and !empty($_POST['meli'])) {
                # data is valid
$result = insertUserData($_POST['name'], $_POST['phone'], $_POST['meli']);
        }
    }
}
?>