Mega, GSM Shield and SD Shield to send data to MySQL using XAMPP

Hopefully I picked the right subject to post this in, as I’m not sure where my error(s) lie.

I’m trying to use the setup described in the title to upload DHT11 sensor data to a table created in a MySQL database using XAMPP.

I unfortunately am not getting any error message at this stage, just no values appearing in my table.

If anyone could spot where I’m going wrong that would be great, as I’m very new to Arduino and have gone in at the deep end I think.

Posted both PHP codes I have tried with many variations.

My MySQL Code:

CREATE TABLE `mydb`.`temphum` (
`temp` VARCHAR( 255 ) NOT NULL ,
'hum` VARCHAR( 255 ) NOT NULL ,
PRIMARY KEY ( `id` )
) ENGINE = InnoDB ;

My PHP code v1.

$link = mysqli_connect("localhost", "root", "", "mydb");
$sql = "INSERT INTO mydb.temphum (temp, hum) VALUES ('".$_GET["temp"]."','".$_GET["hum"]."')";
mysqli_query($link, $sql);

My PHP Code v2.

$link = mysqli_connect("localhost", "root", "", "mydb");
$temp = (isset($_GET['temp']) ? $_GET['temp'] : null);
$hum = (isset($_GET['hum']) ? $_GET['hum'] : null);
$sql = "INSERT INTO mydb.temphum (temp,hum) VALUES (".$temp.", ".$hum.")";
mysqli_query($link, $sql);

My Arduino Code

#include <Wire.h>
#include <HCRTC.h>
#include <SD.h>
#include <dht.h>
#include <SPI.h>
#include <GSM.h>

#define I2CDS1307Add 0x68
#define SD_CS_DIO 53
#define PINNUMBER ""
#define GPRS_APN       ""
#define GPRS_LOGIN     "user"
#define GPRS_PASSWORD  ""
#define DHT11_PIN 8

File DataFile;
dht DHT;
GSM gsmAccess;
GSM_SMS sms;
GSMClient client;
GPRS gprs;

IPAddress server(172,0,0,1);
char path[] = "/insert.php";
int port = 80;

void setup(){
  pinMode(SD_CS_DIO, OUTPUT);
  HCRTC.RTCWrite(I2CDS1307Add, 17, 8, 24, 13, 05, 0, 4);
   if (!SD.begin(SD_CS_DIO)) 
    Serial.println("ERROR: SD card failed to initialise");
    Serial.println("SD Card initialised");
  Serial.println("Starting Arduino Web Client.");
  boolean notConnected = true;
    if((gsmAccess.begin(PINNUMBER)==GSM_READY) &
      notConnected = false;
      } else
      Serial.println("Not connected");
  Serial.println("GSM initialized");
  Serial.println("connected GPRS.");

void loop()
  Serial.print(", ");
  Serial.println(", ");
  int chk = DHT.read11(DHT11_PIN);
  int temp = DHT.temperature;
  int hum = DHT.humidity;
  Serial.print("Temperature = ");
  Serial.print("Humidity = ");

  DataFile ="MegaData.csv", FILE_WRITE);
  if (DataFile) 
    DataFile.print(", ");
    DataFile.print(", "); 
    DataFile.print(", ");
    DataFile.print(", ");
  else {
    Serial.println("error opening csv file");
  if (client.connect(server, 80)) {
    client.print("GET /insert.php?");
    client.println(" HTTP/1.1"); 
    client.println("Connection: close");
    Serial.println("client connection falied\n");

Thanks for any advice or suggestions