Simple Machines Community Forum

Customizing SMF => SMF Coding Discussion => Topic started by: ivimendoza on June 11, 2014, 03:38:50 PM

Title: How SMF sets the order to functions inside the template?
Post by: ivimendoza on June 11, 2014, 03:38:50 PM
Hello,

When I see all the functions inside a file.template.php, I can't really understand how SMF executes it. I guess, this is kinda interpreted by the loadSubtemplates(), but I don't know how it sets the order of execution. For example, in ManageBans.template.php I see this functions: template_ban_edit(), template_ban_edit_trigger(). This functions actually defines all the HTML structure, but I don't understand how it makes the order each other. Can somebody explain me, please? Thanks.
Title: Re: How SMF sets the order to functions inside the template?
Post by: Arantor on June 11, 2014, 03:40:17 PM
The code in ManageBans, in each area, sets the value of $context['sub_template'] to the one that fits the current task at hand...