hellohtml cgi we can make some variation and display an already determined html page rather than plain text try the link you to read#!/usr/bin/env python print("content-typetext/html\ \ "html markup follows print(""hello in html hello therehi there"""there are two noteworthy changes the first print function call now declares the rest of the output will be html this is standard boilerplate line you will be using for your cgi programs the remaining print function call has the markup for an html page note that the enclosing triple quotes work for multi line string other than as simple illustrationthis cgi script has no utilityjust putting the contents of the last print function in file for static web page hello html would be much simpler now cgi one more simple stepwe can have cgi script that generates dynamic output by reading the clock from inside of pythontry the link from static page the code is in the www example directorynow cgiand below for you to read#!/usr/bin/env python import time print("content-typetext/html\ \ "html markup follows timestr time strftime("% "obtains current time htmlformat ""the time now the current central date and time is""print(htmlformat format(**locals()){timestrsee {timestrembedded above this illustrates couple more ideasfirst library moduletimeis imported and used to generate the string for the current date and time the web page is generated like in helloweb pyembedding the dynamic data (in this case the timeinto literal web page format string (note the embedded {timestrunlike helloweb pythis is cgi script so the web page contents are delivered to the server just with print function cgi dynamic web pages