Skip to content Skip to sidebar Skip to footer

Input Data From Android To Database In Mysql

I have this code:

Solution 1:

Found a typo -

 $ins=mysql_query("INSERT into tblentry
     (entId,entSender,entTitle,entTime,entSAGrade,entReason,entProblem)
     VALUES
     ('$entId','$entSender','$entTitle',CURTIME(),'$entSAGrade','$entReason','$entProblem'));"
                                                                                    ^=== This should be inside round bracket


Change to this -

$ins=mysql_query("INSERT into tblentry
                 (entId,entSender,entTitle,entTime,entSAGrade,entReason,entProblem)
                 VALUES
                 ('$entId','$entSender','$entTitle',CURTIME(),'$entSAGrade','$entReason','$entProblem')");

Solution 2:

First you should test your PHP service isolated, e.g. using Chrome's PostMan extension. As you make sure PHP works properly, next step is to connect Android's code to your web service.

Please check PostMan for a nice debugging ;)

https://chrome.google.com/webstore/detail/postman-rest-client/fdmmgilgnpjigdojojpjoooidkmcomcm?hl=en


Post a Comment for "Input Data From Android To Database In Mysql"