|
|
Posted by Jerry Stuckle on 11/02/06 04:59
Cookie Jar wrote:
> I have a situation where I am trying to abstract away not only the
> organization of the presentation (via TPL files) but also some of the
> finer formatting features (via CSS).
>
> So, for a particular request, I want to be able to select a specific
> TPL file to render (easy enough), but I also want to indicate a
> specific CSS file to use with the selected TPL.
>
> Can this assignment be done dynamically, i.e. at runtime? I am hoping
> I can pass the name of the CSS file to the TPL file, as any other
> dynamically assigned tag, but I am unsure whether the TPL file would be
> compiled before or after the CSS file would be assigned.
>
Not that bad. In your header, just add:
<link href="<?php echo $cssfile; ?>" rel="stylesheet" type="text/css">
Where $cssfile is the name of the css filename you wish to use.
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================
Navigation:
[Reply to this message]
|