PHP/Mapscript makes this fantastically easy, with only 19 lines of code! You can download the code here.
The remainder of the post steps you through the process of installing the script and, with a few simple calls, you have a functional map of your chosen location.










