Hey everyone,
so i was working on my website and i noticed something peculiar in the documentation of hunchentoot that i thought i should probably ask about. As i understand hunchentoot has a function called get-uri* which returns the full uri including the query (the thing after the ?) and also has a function called get-query which returns the string that is after the ?. So my question is, is there a function that returns the url without the query string so that i can use my own dispatchers or should i use string manipulation?
Also a side question not related to hunchentoot but that which i would greatly appreciate an anser too, does anyone know of some library that offer mail server ability in lisp or maybe just can recieve emails and offer them for processing (i currently use a modified version of cl-smtp by bknr to send emails.)
Thanks in advance.
Mackram Raydan
Company: www.imagimate.com Website: www.trailoflight.net
"An invasion of armies can be resisted, but not an idea whose time has come." Victor Hugo
The function you're looking for is script-name*
On Mon, Sep 7, 2009 at 10:59 PM, Mackram Raydan mackram@gmail.com wrote:
Hey everyone,
so i was working on my website and i noticed something peculiar in the documentation of hunchentoot that i thought i should probably ask about. As i understand hunchentoot has a function called get-uri* which returns the full uri including the query (the thing after the ?) and also has a function called get-query which returns the string that is after the ?. So my question is, is there a function that returns the url without the query string so that i can use my own dispatchers or should i use string manipulation?
Also a side question not related to hunchentoot but that which i would greatly appreciate an anser too, does anyone know of some library that offer mail server ability in lisp or maybe just can recieve emails and offer them for processing (i currently use a modified version of cl-smtp by bknr to send emails.)
Thanks in advance.
Mackram Raydan
Company: www.imagimate.com Website: www.trailoflight.net
"An invasion of armies can be resisted, but not an idea whose time has come." Victor Hugo
tbnl-devel site list tbnl-devel@common-lisp.net http://common-lisp.net/mailman/listinfo/tbnl-devel
On Mon, Sep 7, 2009 at 21:59, Mackram Raydanmackram@gmail.com wrote:
so i was working on my website and i noticed something peculiar in the documentation of hunchentoot that i thought i should probably ask about. As i understand hunchentoot has a function called get-uri* which returns the full uri including the query (the thing after the ?) and also has a function called get-query which returns the string that is after the ?. So my question is, is there a function that returns the url without the query string so that i can use my own dispatchers or should i use string manipulation?
You should use the SCRIPT-NAME function. It has its name from its CGI heritage. We discussed whether we want to get rid of all those CGI names and use more intuitive ones at some point, but then decided that this would be too intrusive a change.
Also a side question not related to hunchentoot but that which i would greatly appreciate an anser too, does anyone know of some library that offer mail server ability in lisp or maybe just can recieve emails and offer them for processing (i currently use a modified version of cl-smtp by bknr to send emails.)
I have successfully handled incoming emails with imap, using both the mel-base and Franz' own imap libraries. Using imap has the advantage that an existing email infrastructure can be used, which is also its disadvantage. Franz has published an open source smtp server, too, which can propably be made to run using the acl-compat library if you feel that a real mail server would serve you better.
See http://github.com/franzinc for Franz' open source offerings, http://www.cliki.net/ACL-COMPAT for the Allegro CL compatibility library acl-compat, and http://common-lisp.net/project/mel-base/ for the mel-base project.
-Hans