I found a solution on my own... why didn't I try this before?

data='{u:"'+$('#loginname').val()+'",p:"'+$('#loginpassword').val() +'",r:"'+$('#loginremember').val()+'"}';
becomes
data='u="'+$('#loginname').val()+'"&p="'+$('#loginpassword').val() +'"&r="'+$('#loginremember').val()+'"';

I'd love some comments on this as a solution, it seems to work but... is it like legit? (it does work now though)

Cheers,
Tamm Sjödin



On 7 May 2007, at 00:30, Tamm wrote:


Hi I'm feeling very stupid asking this but here goes:

I'm sending something like this
$.post("/scripts/login.php",{u:"USER",p:"PASS",r:"STAY"},function(txt)
{$("div#"+div).html(txt);});

but the php $_POST[''] array get's no data...

now please tell me how stupid I am :)


Reply via email to