'\nb'<html xmlns=" '\nb'\nc:\pp \internet\otherhttp-getfile py www python org index html www python org index html error sending request bad request :\pp \internet\otherhttp-getfile py www rmi net /~lutz www rmi net /~lutz error sending request moved permanently :\pp \internet\otherhttp-getfile py www rmi net /~lutz/index html www rmi net /~lutz/index html '\nb'\nb'\nb"mark lutz' book support site\nb'\nb'\nnotice the second and third attempts in this codeif the request failsthe script receives and displays an http error code from the server (we forgot the leading slash on the secondand the "index htmlon the third--required for this server and interfacewith the raw http interfaceswe need to be precise about what we want technicallythe string we call filename in the script can refer to either simple static web page file or server-side program that generates html as its output those serverside programs are usually called cgi scripts--the topic of and for nowkeep in mind that when filename refers to scriptthis program can be used to invoke another program that resides on remote server machine in that casewe can also specify parameters (called query stringto be passed to the remote program after herefor instancewe pass language=python parameter to cgi script we will meet in (to make this workwe also need to first spawn locally running http web server coded in python using script we first met in and will revisit in )in different window :\pp \internet\webwebserver py webdir "port :\pp \internet\otherhttp-getfile py localhost /cgi-bin/languages py?language=python localhost /cgi-bin/languages py?language=python 'languages\nb'syntax\nb'python\nbprint('hello world'\ client-side scripting