lisp - with hunchentoot I cannot generate web pages -


i learning common lisp , trying use hunchentoot develop web apps.

with code below cannot manage see page defined in retro-games function definition on browser. expect generated function.

i write address as:

http://localhost:8080/retro-games.htm. 

what displayed on browser resource /retro-games.htm not found, message , lisp logo @ default page, display. can display hunchentoot's default page.

(ql:quickload "hunchentoot") (ql:quickload "cl-who")  (defpackage :retro-games   (:use :cl :cl-who :hunchentoot)) (in-package :retro-games);i evaluate toplevel otherwise not change package.  (start (make-instance 'hunchentoot:acceptor :port 8080))  (defun retro-games ()     (with-html-output (*standard-output* nil :prologue t)       (:html (:body "not there"))       (values)))  (push (create-prefix-dispatcher "/retro-games.htm" 'retro-games) *dispatch-table*) 

the 2 loadings @ beginning successful.

what missing?

hunchentoot's api has changed bit since written. behaviour of acceptor assumed article found in easy-acceptor. acceptor more general class now, can use own dispatch mechanism, if inclined.

so, instead of (make-instance 'hunchentoot:acceptor #|...|#), use (make-instance 'hunchentoot:easy-acceptor #|...|#), , should work.


Comments

Popular posts from this blog

javascript - Laravel datatable invalid JSON response -

java - Exception in thread "main" org.springframework.context.ApplicationContextException: Unable to start embedded container; -

sql server 2008 - My Sql Code Get An Error Of Msg 245, Level 16, State 1, Line 1 Conversion failed when converting the varchar value '8:45 AM' to data type int -