let user = "david.ortiz"; let q = "all"; $.post("/scripts/materials.php",{user:user,type:type},function(response){ console.log(response); });