Insert Data Into a Database using Android, PHP, MySQL, JSON Part 1/2

Insert Data Into a Database using Android, PHP, MySQL, JSON Part 1/2
☑ Visit fb page: 

RRelated Posts

The Rise and Fall of Java

Few people know that Java, the worlds most popular programming language, the one that powers smartphone apps and Mars rovers alike, was the result of a project to build a better TV

How KaiOS Is Becoming the 3rd Major Mobile OS

Sponsored by Brilliant. The first 200 get 20% off their subscriptions at http://brilliant.org/TechAltar Google has just invested $22 million into an operating system called KaiOS. Can it become the


  • eChain Technology
    Hello Filip, great tutorial, thank-you so much! How do you modify the insertstudent.php script when data body comes like this format below. I.e., comma separated tabular data with no named fields? This is BLE sensor data with 4 distinct elements. I extracted the POST body data using uBeac Hook. Thanks again!
  • gnappo3000
    why error $connect never user? thanks
  • Ajay Ravindran
    Please explain the exact location where files connection.php and insertStudent.php are stored....
  • madhuka melan
    thank you, thank you, thank you sirrr....
  • Charlie Sv
    Excellent tutorial do it with:
  • Chesney Lesego Zulu
    You are the master, thank you for the great tutorial
  • Maria Shaira Itong
    I really can't insert data. If I type my url it always say "Object not found". Anyway, I'm using XAMMP server. Please help
  • Code Man
    Please make a video how to insert image into the data base
  • Lazy Script
    how many kind software for following this tutorial? i want to try this amazing videos! very cool dude ! #replyplease
  • Afaq Reports
    Its an Amazing Video i ever found on YouTube, as i am totally new to programming plz let me know if i wanna change Database Name or add more fields in database where and which code lines also i need to change.it maybe a stupid question but i need this info
  • Razer Carpo
    Sir what kind a browser did you use cause mine is just blank
  • Ravindra Meena
    I followed tutorial steps and it worked. But i want to know one thing that whatever we did all these as localhost so, what can i do for storing database online.
  • Suchi Degala
    im nt getting json values ,it showing null
    wt shud i d0?
  • Meeru Productions
    Dude there are some changes made in new version so database queries are not working like mysqli_query($connect,$query) .. please check this issue
  • Renato de Oliveira Lucena
    Very good, gave to understand a little about json, I need to use this in a Laravel project. Thank you! ("Muito bom, deu para entender um pouco sobre json, preciso usar isto em um projeto Laravel. Obrigado!") ... Brazil.
  • FunVid Jpr
    have to give any permission to mysql?
  • FunVid Jpr
    im getting json response from the postman,and app runs as well bt inserting and showdata was not working
  • FunVid Jpr
    HI filip,
    i did as wat u did in video bt my app dosnt connect to android, what could b the problem,
    any idea?
  • Raozhon_tb
    Where do i put the .php files ?
  • The Elite DevTeam
    my bad, It was something i did wrong I fixed it
  • The Elite DevTeam
    hi, your tutorial works great on lollipop and above but on pre lollipop devices it doesn't work
  • Victor Fernando
    I am happy after six hours, you is guy!!! Thanks
  • artur russo
    fucks sake not working
  • Ahmed Fadul
    good job brother
  • Temper Damodar Chowdary
    i wrote php code in notepad++ and im using XAMPP server
  • Temper Damodar Chowdary
    i didnt get the result ...please help me
  • Temper Damodar Chowdary
    good , excellent tutorial ........
  • thang nguyen
    Greate job man, thanks you very much, but when t load the link of showStudents.php on http://codebeautify.org, it can't load the Json same the postman ?
  • Thareq abdul aziz
    thank's sir :)
  • Harshitha Reddy
    hey am not able to get the url to link android to php files
    how do i get that?
  • Tharindu Dissanayaka
    I have move my php files to www folder..when I past the url http://localhost/trends/user_control.php  postman says that "unexpected" ...I check the code two wise but their is no issue on code ..plz help me ...
  • mahmoud shaltoot
    great tutorial .. thank u so much
  • Luis
    how i can find the url so i can use on postman
  • Ruchi Jha
    Where do i save my php file so that it gets connected to postman in xampp server.
  • Matt Hoing
    Great tutorials! I am using PHPStorm and Wampserver. I can't seem to get postman to talk to the database just get 404 page not found or got packets out of order warning. Project file is in C:/XAMPP/HTDOCS/ any ideas? Do i need to navigate to the file using command prompt and use the 8080 port?
  • ALaadin Ezher
  • Garry Anderson
    please. take me as your understudy!
  • Garry Anderson
    please. take me as your understudy!
  • crunkmann11
    none of your tutorials work for me! wtf man this is bullshit, i follow your steps one by one and it never fucking works. Turd.
  • Axl Rosel Jaro
    Why do i keep getting the error: "Could not get any response"?
  • inHell
    Hey mate! Thank You!
    This video simplified my start that much; it's really kickstarting it^^
    But one question, because I got a much bigger picture in view.

    If One edits a table and adds columns to the table, then One has to write the code for the columns etc; can One evade that issue? Maybe with a placeholder or are there other commands for this?
  • Angel Sanchez
    hi Filip Vujovic your code works perfectly, i had tested the project on XAMPP which works completely great but when it comes to my webpage hosted in 000webhost.com the showStudents php file doesn't work. insertStudent does function perfectly on my site just in showStudents case.
    It looks like this : http://prntscr.com/9nh1vy.
    please help me out
  • ryan andri
    hi +Filip Vujovic, i want ask to you, what app you use at this video to debug or test thats php ?
    pls tell me what the name thats app, thanks.
  • grant amaral
    Thanks. Great tutorial. I had to fiddle with the php and mysql statement to get the info from the DB. How would I get a success statement upon insertStudent? Is it in the php or in the MainActivity?
  • Nawaz
    What If I use cloud server ?
    Where should I keep the php file then?
  • Himmat Kumar
    After using this code when i launched my app it is stopping.. can u tell what can be the problem?
  • KAON
    I put the php file server, but it does not add
  • José Nobre
    How can I put the information that is on database into a ListView in android. Can u plz help me @FilipVujovic
  • forhad methun