Short answer, depends.
Long answer; its definitely easiest if your Template is based on Masterpage (WebForms) due to its Lifecycle pipeline.
For instance, you can in your function do
Long answer; its definitely easiest if your Template is based on Masterpage (WebForms) due to its Lifecycle pipeline.
For instance, you can in your function do
HttpContext.Current.Items["bodyClass"] = "someBodyClass".
In your Template you mark your body-tag with a runat="server" attribute, and in your PreRender event you add pull out the value from HttpContext.Current.Items["bodyClass"]
and assign it to the body.