Created
February 4, 2016 13:56
-
-
Save KingC100/412d79165bf02f7fd991 to your computer and use it in GitHub Desktop.
p.262
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun hello-request-handler (path header params) | |
(if (equal path "greeting") | |
(let ((name (assoc 'name params))) | |
(format t "HTTP/1.0 200 OK~2%") | |
(if (not name) | |
(princ "<form>What is your name?<input name='name' /></form>") | |
(format t "Nice to meet you, ~a!" (cdr name)))) | |
(princ "Sorry... I don't know that page."))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment