Commits

Cédric Bonhomme committed b9c9e08

Works nos as CGI.

Comments (0)

Files changed (1)

     quote := rand.Intn(nb_quotes)
 
     // Now use the Quote structure
-    fmt.Println("Citation: \"" + quotes.Quotes[quote].Citation + "\"")
-    fmt.Println("Author: \"" + quotes.Quotes[quote].Author + "\"")
-    fmt.Println("Year: \"" + quotes.Quotes[quote].Year + "\"")
+    os.Stdout.WriteString("Content-Type: text/plain;charset=us-ascii\n\n")
+    os.Stdout.WriteString("Citation: \"" + quotes.Quotes[quote].Citation + "\"")
+    os.Stdout.WriteString("Author: \"" + quotes.Quotes[quote].Author + "\"")
+    os.Stdout.WriteString("Year: \"" + quotes.Quotes[quote].Year + "\"")
 }