fpWeb_tutorial says that TSimpleFileModule is used to send files.
Look here for webserver: https://wiki.lazarus.freepascal.org/fpWeb_Tutorial#Webserver_example
Yes, your link shows the httproute way of things. BTW, I did not use TSimpleFileModule in my experiment.
Sorry, actually the wizard had added
TSimpleFileModule in the .lpr file for some reason. It only calls a class procedure and sets a class variable, thus no objects are created which is OK.
Yes, the
httproute system shown by @Nimbus should be the way to go for new users.
However the "HTTP Server Application" wizard does not generate such code. It should be improved. At the bottom it has "
Web module to create:". The first option could be "
No module, use httproute" or something like that.
The wiki page should be updated, too. The "Hello World" is done in an outdated way (and its URL doesn't work). Somebody with better knowledge please update it.
I can look at the wizard. I guess Michael Van Canneyt is busy and will not fix it anytime soon.
BTW, how to extend a
httproute app? If I only serve HTML pages, do I need to create any modules at all? I will go through the examples ...