Hi! im currently trying to do a Wemos(my first time using Wemos and doing html-related)
i wonder what is the code for creating input box where i can input my name, numbers. for example, if input numbers, the servo motor will rotate on respective angle.
i have 0 knowledge about this and whenever i search i can barely find one(while the others require Ajax, SQL or sort)
i really do hope you can help~!
this code is an Example Code from WifiAccessPoint
Hi! i wonder what should be the code for inputting integers in a website.? so what im doing right now is to create a website 194.34.ip.ip/ , using Wemos. there will be an input box there and I will a input numbers from 1-100 then it will send to Wemos that will display the input as text in LCD. the problem is i never experienced HTML or web related designing. so coding one looks difficult.
my code:
#include <ESP8266WiFi.h>
#include <WiFiClient.h>
#include <ESP8266WebServer.h>
#ifndef APSSID
#define APSSID "Wemostest"
#define APPSK "12345678"
#endif
/* Set these to your desired credentials. */
const char *ssid = APSSID;
const char *password = APPSK;
const int S
ESP8266WebServer server(80);
/* Just a little test message. Go to http://192.168.4.1 in a web browser
connected to this access point to see it.
*/
void handleRoot() {
server.send(200, "text/html", "<h1>You are connected</h1>");
server.send(200, "input/html"
}
void setup() {
delay(1000);
Serial.begin(115200);
Serial.println();
Serial.print("Configuring access point...");
/* You can remove the password parameter if you want the AP to be open. */
WiFi.softAP(ssid, password);
IPAddress myIP = WiFi.softAPIP();
Serial.print("AP IP address: ");
Serial.println(myIP);
server.on("/", handleRoot);
server.begin();
Serial.println("HTTP server started");
}
void loop() {
server.handleClient();
}
i havent included the LCD yet but that will be easy i think. only the website part is difficult
@Leocann Your topics on the same subject have been merged
HTML Input Types helps you. With examples.
This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.