This code is not working properly. What i want is just send the variable $something to the page.php
What is the correct way to do this ? : data: <? php $something; ?>,
script
$something = "text";
$.ajax({
url: "page.php",
type: "post",
dataType: "html",
data: <? php $something; ?>,
success: function (data) {
$('#total').load('xxx.php');
}
});
myFile.php: