Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
Jifty::View::Mason::HaUserrContributed Perl DocuJifty::View::Mason::Handler(3)

NAME
       Jifty::View::Mason::Handler - Handler for Mason requests	inside of
       Jifty

SUMMARY
       Jifty controls all of the input and output from the Mason templating
       engine; this means that we cannot use the Mason's standard
       HTML::Mason::CGIHandler interface to interact with it.

   new PARAMHASH
       Takes a number of key-value parameters; see HTML::Mason::Params.
       Defaults	the "out_method" to appending to "buffer" in Jifty::Handler
       and the "request_class" to Jifty::View::Mason::Request (below).
       Finally,	adds "h" and "u" escapes, which	map to "escape_uri" and
       escape_utf8 respectively.

   config
       Returns our Mason config.  We use the component root specified in the
       "Web/TemplateRoot" framework configuration variable (or "html" by
       default).  Additionally,	we set up a "jifty" component root, as
       specified by the	"Web/DefaultTemplateRoot" configuration.  All
       interpolations are HTML-escaped by default, and we use the fatal	error
       mode.

   escape_utf8 SCALARREF
       Does a css-busting but minimalist escaping of whatever html you're
       passing in.

   escape_uri SCALARREF
       Escapes in-place	URI component according	to RFC2396. Takes a reference
       to perl string.

       *Note* that octets would	be treated as latin1 encoded sequence and
       converted to UTF-8 encoding and then escaped. So	this sub always
       provide UTF-8 escaped string. See also Encode for more info about
       converting.

   template_exists COMPONENT
       Checks if the "COMPONENT" exists, or if "COMPONENT/index.html" exists,
       and returns which one did.  If neither did, it searches for "dhandler"
       components which	could match, returning "COMPONENT" if it finds one.
       Finally,	if it finds no possible	component matches, returns undef.

       Note that this algorithm	does not actually decisively return if Mason
       will handle a given component; the dhandlers could defer	handling, for
       instance.

   show	COMPONENT
       Takes a component path to render.  Deals	with setting up	a global
       HTML::Mason::FakeApache and Request object, and calling the component.

   handle_comp
       A synonym for show

   request_args
       The official source for request arguments is from the current
       Jifty::Request object.

   create_cache_directories
       Attempts	to create our application's mason cache	directory.

perl v5.24.1			  2013-01-29	Jifty::View::Mason::Handler(3)

NAME | SUMMARY

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=Jifty::View::Mason::Handler&sektion=3&manpath=FreeBSD+12.1-RELEASE+and+Ports>

home | help