You could get the user form data, generate the plot calling gnuplot and return a page with the image file.
That's exactly what I want to do. I'm already using python to dynamically configure gnuplot to generate png files for reports. I just want to do this from a web interface for other people to be able to view the results (it'll probably be used for teaching.) I would rather use python if possible, while I know the basics of hacking together a php page (it's not hard really), the other server size software I've currently built is in python so that would be one less language that I'd have to keep in my head while completing this project.
I'll have a play around with bottle and see how far I get.
The bottle.py tutorial covers what you need, apart from generating the plot itself. Since the default http server offered by bottle.py is single-threaded, the server will be busy handling the request (calling gnu plot) and no other requests will be served meanwhile. This is a problem if there are more than one user accessing the website at the same time. If that is required you may switch to other servers like "paste". It is a matter of installing it (a python package), and changing a line in your code. In general, it is better to have multithreaded servers since even accessing a single web page usually involves several requests (html, css, images, js files, etc).
http://bottlepy.org/docs/dev/deployment.htmlA python http server may be enough if the server is going to be hosted in a machine in a LAN. If you intend to use an internet hosting service, you'll probably need to go the apache route because you may not have permissions to start your own http server. For example, I've run bottle.py apps in dreamhost shared hosting through apache. Another option, in case you have a VPS or a dedicated server, is to just run bottle.py there using a python http server like paste, and not install apache. I have done that in a minimal 128mb VPS.
Keep in mind that in case the server is multithreaded you may have more than one request at the same time, so you need to be able to generate plots in parallel, or use locks to serialize the process.