[jQuery] how can I call php function in jquery ?
I have in PHP file ajax.php:
class Data
{
public function __construct()
{
....................
}
public function select($idl)
{
....................
}
public function delete($id)
{
.....................
}
}
My jquery function looks now:
function deleteComment(id)
{
$.post("ajax.php",
{
},
function(data) {
...........
}
);
}
How can I in function deleteComment(id) call php function delete($id)
from file ajax.php ?