Closed ngocdaothanh closed 15 years ago
Well - you can't have both. Either an appmod is responsible for all data below /xxx or it isn't.
Steve Vinoski suggested:
Isn't the answer to issue #5 to just have a "for everything else" out/1 function in the appmod that just does a {page, ...} to tell Yaws to send the file instead?
And - I think this will work fine.
Either an appmod is responsible for all data below /xxx or it isn't.
I mean: (1) if the path is /xxx/yyy/zzz, Yaws should pass the request to the appmod, (2) if the path is exactly /xxx, Yaws should serve the static file.
Currently, when running on Yaws the Nitrogen web framework (http://nitrogenproject.com/) must use the path /web/yyy/zzz for all dynamic contents. And the /web prefix is ugly.
Regards.
Ok,
Have you tried the {page, Page} suggestion for the top level page ?
{page, Page} works: http://groups.google.com/group/nitrogenweb/browse_thread/thread/c2ce70f696b77c9e
Thanks a lot.
Since {page, Page} works as expected, closing this issue.
OTOH, - and I've my self come across the very same issue discussed in the google group mentioned above. One possible - and light weight solution could be to assign an exception list to an appmod. That way it would be possible to have an appmod for / but let everything under e.g. /static be directly served by yaws.
?
I think that's a good idea.
If there are:
More information: http://wiki.github.com/klacke/yaws/root-appmod