webmcp
diff framework/env/slot/set_layout.lua @ 509:6c819040ef6f
Further improvements to WebMCP documentation
author | jbe |
---|---|
date | Mon Aug 21 01:33:17 2017 +0200 (2017-08-21) |
parents | e7c9a80b6795 |
children |
line diff
1.1 --- a/framework/env/slot/set_layout.lua Sun Aug 20 23:27:20 2017 +0200 1.2 +++ b/framework/env/slot/set_layout.lua Mon Aug 21 01:33:17 2017 +0200 1.3 @@ -6,7 +6,7 @@ 1.4 1.5 This function selects which layout should be used when calling slot.render_layout() (as done by request.handler(...)). If nil is selected as layout, then no layout will be used, but the slot named "data" is used plainly. The second argument to slot.set_layout is the content-type which is sent to the browser. 1.6 1.7 -The default layout for views is "default". Actions have no default layout, but an explicit call of slot.set_layout(...) (even with nil as first argument) during request handling will cause subsequent calls of slot.layout_is_set() to return true which indicates that content (e.g. via slot.put_into("data", ...)) is available and should be rendered instead of using the action's return value to forward or redirect the user agent. 1.8 +The default layout for views is "default" (but errors get a default layout named "system_error"). Actions have no default layout, but an explicit call of slot.set_layout(...) (even with nil as first argument) during request handling will cause subsequent calls of slot.layout_is_set() to return true which indicates that content (e.g. via slot.put_into("data", ...)) is available and should be rendered instead of using the action's return value to forward or redirect the user agent. 1.9 1.10 --]]-- 1.11