how to add styles and javascript, to smarty application, in the head section  written the styles code but when we are applying that code to the tpl file is not applied is there any separate code to written in the smarty.

for that reason go to below code

we can the simple code in the smarty application for style sheet and javascript , we add the add one keyword in the tpl files, then

{literal}
<style type=”text/css”>
.style1
{
font-family:Arial, Helvetica, sans-serif;
color:#666666;
}
</style>
{/literal}

It will be useful.

Categories: Smarty

3 Comments

[email protected] · December 20, 2013 at 9:41 am

in the above example
{literal}
is syntax or any abstract content in html…………?

    [email protected] · December 20, 2013 at 9:42 am

    and please lable the text boxes lying below “Leave a Reply” section ………..

    Anil Kumar Panigrahi · December 20, 2013 at 9:46 am

    {literal} will use in the Smarty template engine, Not in the regular format of HTML.

Leave a Reply

Avatar placeholder

Your email address will not be published. Required fields are marked *