创建另一个文件的 NodeMCU 最终用户设置模块 html 文件

NodeMCU enduser setup module html file that creates another file

我已经创建了自己的 enduser_setup.html 文件 nodemcu(对于最终用户设置模块:https://nodemcu.readthedocs.io/en/master/en/modules/enduser-setup/#enduser_setupstart)。

我添加了另一个字段(在 ssid\password 字段之外):

<input id=result1 type=text autocorrect=off autocapitalize=none placeholder='Place ID' /> 

我想在提交时使用该字段的获取结果创建一个 lua 文件 (result1.lua)。

尝试过 php:

<?php
    $myfile = fopen("result1.lua", "w") or die("Unable to open file!");
    $txt = $_GET["result1"];
    fwrite($myfile, $txt);
    fclose($myfile);
?>

没用:(

NodeMCU 目前无法做到这一点。但是,有一个 pending pull request 将添加此功能。它可能会在接下来的几天内合并到 dev 分支。