<<

NAME

C4::Templates - Object for manipulating templates for use with Koha

NAME

C4::Templates - Functions for managing templates

FUNCTIONS

badtemplatecheck

    badtemplatecheck( $template_path );

    The sub will throw an exception if the template path is not allowed.

    Note: At this moment the sub is actually a helper routine for
    sub gettemplate.

themelanguage

    my ($theme,$lang,\@themes) = themelanguage($htdocs,$tmpl,$interface,query);

This function returns the theme and language to be used for rendering the UI. It also returns the list of themes that should be applied as a fallback. This is used for the theme overlay feature (i.e. if a file doesn't exist on the requested theme, fallback to the configured fallback).

Important: this function is used on the webinstaller too, so always consider the use case where the DB is not populated already when rewriting/fixing.

getlanguagecookie

    my $cookie = getlanguagecookie($query,$language);

Returns a cookie object containing the calculated language to be used.

GetColumnDefs

    my $columns = GetColumnDefs( $cgi )

It is passed a CGI object and returns a hash of hashes containing the column names and descriptions for each table defined in the columns.def file corresponding to the CGI object.

<<