I would like to show this json response data in a sectioned UItableView on my iPhone. the sections should be the first letter of the customer name.
here it is http://mobile.beger.org/getdata.php53?object=customer&mode=all
How do i have to change my mysql_fetch_object? and how do i implement it in my objective-c code?
$rs = mysql_query("SELECT LEFT(CUSTOMER_M.s_name1,1) as FirstLetter,CUSTOMER_M.i_customer_m, CUSTOMER_M.s_name1, COALESCE(CUSTOMER_M.s_town,'unbekannt') as s_town FROM `CUSTOMER_M` WHERE CUSTOMER_M.I_CUSTOMER_M > 0 ORDER BY CUSTOMER_M.S_NAME1");
while($obj = mysql_fetch_object($rs)) {
$arr[] = $obj;
}
echo '{"customer":'.json_encode($arr).'}';
Thanks for your help!