I am getting the following syntax error from firebug:
SyntaxError: missing ) after argument list
$.ajax({ //create an ajax request to load_page.php
type: "POST",
url: "display.php",
data:{faculties:faculty},
dataType: "json", //expect json to be returned
success: function(response)
{
$.each(response,function(i,item)
{
$("table tbody").append("<tr><td>"+response[i].code+"</td>"+"<td>"+response[i].title"</td>"+"<td>"+response[i].lecturer"</td"+"<td>"+response[i].description"</td></tr>");
// The line above is giving me the
// syntax error , i cant figure out what's wrong
});
}
});
This is the JSON object being passed by the PHP script
$data[]=array("code"=>$code,"title"=>$title,"lecturer"=>$lecturer,"description"=>$description);
I have spend 1 hour debugging but I can't find the syntax error. Can you guys help me out?