Jump to content

larghifra

New Members
  • Posts

    3
  • Joined

  • Last visited

larghifra's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Thank you for your answer! Sorry can you explain me where i can set the error reporting and display errors?
  2. @Barand so how i should modify the script? Removing 'siss' parameter? How can i put query result into array?
  3. Hi everyone, i'm a new user and i'm making some test on 000webhost to host a database for a simple application. I created a MySQL database that contains a simple table you can see here: I made a simple android app which sends a Json request to this simple php file loaded into "public_html" folder in my 000webhost page. <?php $conn = mysqli_connect("localhost", "myuser", "mypassword", "mydatabase"); $name = $_POST["name"]; $email = $_POST["email"]; $password = $_POST["password"]; $statement = mysqli_prepare($conn, "INSERT INTO user (name, email, password) VALUES (?, ?, ?)"); mysqli_stmt_bind_param($statement, "siss", $name, $email, $password); mysqli_stmt_execute($statement); $response = array(); $response["success"] = true; echo json_encode($response); ?> The application works correctly and receives the "success" response back equals to "true", so the php script runs correctly too, but in the database it doesn't happen anything. Maybe i made some error in the php script, i don't know, please help me!!
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.