Your new topic does not fit any of the above??? Check first. Then post here. Thanks.

Moderator: igrr

User avatar
By josephchrzempiec
#83081 Hello i only recently figure out how to add new webpages to the esp8266. But the question is it possible to dynamically create a webpage from the browser on the Esp8266? I have enough space i did upgrade my flash chip. So I was just wondering. A Friend of mine Hari he has a awesome youtube channel we had a talk and he said possibly able to do it but he wouldn't know how. So I'm asking the whole esp community if something like this can be done?


Joseph
User avatar
By rudy
#83093
is it possible to dynamically create a webpage from the browser on the Esp8266?

I'm not sure what you mean. What I think you are asking is can the user use a webpage on the ESP8266 to create another webpage. Yes they can, but the next question is how to accomplish it.

The easy way is to give the user a text editor on the ESP8266, where they can type in the new webpage code, or edit some existing code. The fsbrowser.ino example has a text editor available and can be used of this.
https://github.com/esp8266/Arduino/tree ... /FSBrowser

But I'm sure that is not what you want. It would be too hard for most users to create a web page by typing in all the code.

If you wanted a form where the user could select different options, and that data would be used by the ESP8266 to create a new webpage. Then yes that is possible.

With the right javascript code (in the initial web page) you can make a very user friendly webpage builder application served from the ESP8266. The more sophisticated the application the more complex the code to achieve it.
User avatar
By Bonzo
#83095 Dynamic pages to me mean using php and I doubt you will be able to do that.

I do not know how you will write to a memory with just html. I suppose you could create/modify a page with JavaScript as rudy suggests but when the browser is closed the modified page would be lost.
User avatar
By rudy
#83097 First it needs to be clear if you want a dynamic webpage that changes based on information accessible to the ESP8266 (dynamic content), or if you are looking to create a new webpage with an existing webpage on the ESP8266.

A webpage with dynamic content is often done. Creating a new page with a current page typically is not done. I have a project where I need the user to enter some information on the assembled system, and that information is used to create a page layout with the components that the user specified. This resultant page will be specific to that user's setup. If someone else went through the same procedure, but with different components, the resultant page will be different. Both show information from all the ESPs in their system.

Without specifics, it is hard to say if what you want to do is practical.