I am currently using the script below to fill some divs with data i need
function fillLeagues(){
var load = $.get('drawleague.php');
$(".really").html('Refreshing');
load.error(function() {
console.log("Mlkia kaneis");
$(".really").html('failed to load');
// do something here if request failed
});
load.success(function( res ) {
console.log( "Success" );
$(".really").html(res);
});
load.done(function() {
console.log( "Completed" );
});
}
I was wondering if it was possible to call a certain function in the drawleague.php file that will return the info since i don't wanna use say 10 php files to fill 10 divs for example.