Arduino Uno Wifi REV 2 - Posting temp values to SQL database using WiFiNINA

Hey all! I am really hoping you can assist me. I have been working on this for weeks!

I have been testing and trying to post my temp values from my Arduino to an SQL database over wifi. For some reason, the values cannot be sent! Every time it connects, it just write blanks in the SQL database. Maybe you can see something I am not?

I am connecting to my local host server and writing into my local phpadmin database. Please let me know if you need anything else!

#include <SPI.h>
#include <WiFiNINA.h>
// EDIT: Change the 'ssid' and 'password' to match your network
char ssid[] = "";  // wireless network name
char password[] = ""; // wireless password
int status = WL_IDLE_STATUS;
WiFiClient client;

//String query = "temp=2300&humid=5000";

void setup() {
  // Open serial communications and wait for port to open:
  // this check is only needed on the Leonardo:
  while (!Serial) {
    ; // wait for serial port to connect. Needed for Leonardo only

  // check for the WiFi module:
  if (WiFi.status() == WL_NO_MODULE) {
    Serial.println("Communication with WiFi module failed!");
    // don't continue
    while (true);
  // attempt to connect to Wifi network:
  while (status != WL_CONNECTED) {
    Serial.print("Attempting to connect to WPA SSID: ");
    // Connect to WPA/WPA2 network:
    status = WiFi.begin(ssid, password);

    // wait 10 seconds for connection:
  //pinMode(7, OUTPUT);


void loop()
  int temp;
temp = 1;

Serial.print("Yeah... it ain't holding");
 //int temp = 4;
 // int humid = 5;

  if (client.connect("please put ip for your local host", 80))
    client.println("GET /insertmysql.php?temp=");
    client.println(" HTTP/1.1");
    //client.println("Content-Type: application/x-www-form-urlencoded; charset=UTF-8");
    //client.print("Content-Length: ");
    //int thisLength = query.length();
  Serial.println("Response: ");
  while (client.connected() || client.available())


$tempf = $_POST["temp"];
/*$humid = $_POST["humid"];

/*$temp = "";
$humid = "";

if (isset($_GET['temp'])){
   $temp = $_GET['temp'];
   echo $temp;
   echo "Data not received\n";

if (isset($_GET['humid'])){
   $temp = $_GET['humid'];
   echo $humid;
   echo "Data not received\n";
echo("at least something\n");
//echo json_encode($_POST);
// EDIT: Your mysql database; account information
$servername = "";
$username = "";
$password = "";
$dbname = "";
//$test = 100;
// Create connection
$conn = mysqli_connect($servername, $username, $password, $dbname);
// Check connection
if (mysqli_connect_error()) {
    die("Connection failed: " . mysqli_connect_error());

//$temp = mysqli_real_escape_string($conn, $temp);

$sql = "INSERT INTO alldata (temp) VALUES ('$temp')"; 
if (mysqli_query($conn, $sql)) {
    echo "New record created successfully";
} else {
    echo "Error: " . $sql . "
" . mysqli_error($conn);

//echo 'GET temp = ' . htmlspecialchars($_GET["temp"]) . '';


You have not worked on your code since the last time you posted your question. Did you have a look at the points I made about your code?

Sorry I do apologize! It's my first time using such a thing and I did not realize I have to click into it to read replies. I'll give it a shot and let you know!