   }
   server.send(200, "application/json", "{\"status\":\"complete\"}");
 }
+
+// Literally returns the temperature
+float getTemperature() {
+  return dht.readTemperature(true);
+}
+
+// Send temp / humidity update
+void checkTempHumid() {
+  Serial.println("Checking temp...");
+  float readTemp = getTemperature();
+  dtostrf(readTemp, -6, 2, temp); // Leave room for too large numbers!
+
+  Serial.println(temp);
+}

      }
    }
    lastPowerCheck = millis();
  }
  // Check status to update variables
  computerOn = digitalRead(POWER_LED);

#define RELAY_PIN D1
#define POWER_BUTTON D4
#define POWER_LED D2
#define DHT_PIN D5

#define DHTTYPE DHT22        // DHT 22
DHT dht(DHT_PIN, DHTTYPE);

// The port to listen for incoming TCP connections
ESP8266WebServer server(80);

// How often to report temperature
unsigned long lastTempCheck = millis();
#define TEMP_CHECK_FREQUENCY 10000

// How often to check for power off state
unsigned long lastPowerCheck = millis();
