I noticed that routers use a web interface for configuration. What language does it use, and how does it remember settings that the user has selected?
Does the router use Apache and PHP?, or something else?
The web inteface is served by a mini webserver, not necessarily apache. Depends on the router. Linksys for example uses VMS while Buffalo uses linux.