Hiya,
I'm having a little bit of trouble understanding this - hope you can
help!
I can't seem to write a function which takes arguments, turns these
into a mootools request and then returns the response from the server
side script.
So far i have...
function text_to_db(text,table,field,id){
var text_to_db = new Request({method: 'get', url: "../assets/
controllers/text_to_db.php"
, onSuccess: function(response){
makeChanges(response)
}
})
var string =
"text="+text+"&table="+table+"&field="+field+"&id="+id;
text_to_db.send(string);
function makeChanges(response){return response};
}
But it always returns undefined.
I think it has something to do with this thread but i've spent a good
few hours trying to work it out and i'm stumped.
Hope you can help,
Dan