I was doing a survey I was offline server so I save users information in cookies, I have users Information like this
Fname:Ali,Lname:Kheiri,title:Director,o
you should get the cookie value as a string split it and have every criteria alone than use the insert query because the query you wrote is incorrect you saying insert into user_data the first name the last name the job title... but you are only giving him 1 value the $cookie but the sql don't know that the $cookie contain everything so you should first slpit the cookie value based on the ','