The knowledge of how to do that is not particular to Arduinos or ESP8266s. My suggestion is that you learn how to do it with code on your PC and then when you know how it is done you can transfer your learning to the ESP8266. There will be many more online tutorials about web programming on a PC. You can easily set up a small server on your PC that an be accessed by the browser on the same PC. I use the Python Bottle web framework for my web programming. With it you can probably get a basic server working within 10 or 15 minutes.
The w3schools website is probably a good place to start learning about web programming.