Jump to content

Template System Help.


ipwnzphp

Recommended Posts

Hello, I'am coding a template system and i have an idea of what i want it to do. I have the basics down where i have a main.php page and i use {header} {footer} and such to layout the pages to put the content where i want it. But the question is OS Commerce has a thing called STS Templates and u use 1 page to theme the whole site. u put $content where you want the content and it shows every sub page with content right there. How can i get my system im coding to do that also? Much help well be very appreciated!  ;D
Link to comment
Share on other sites

On your main.php page wherever you want your content, just put that var.
so if you have a header.php and footer.php it sounds like you do this:
<?
require_once('header.php');
$content;
require_once('footer.php');
?>

You should check the support forums for the software though, they likely have documentation for it.
Link to comment
Share on other sites

[quote author=redbullmarky link=topic=123503.msg510612#msg510612 date=1169482176]
maybe at this stage it'd be better to follow obsidians advice and look through Smarty (as well as templates such as bTemplate, phpSavant, etc) to see how they work.
[/quote]
Or read the OS Commerce documentation, or check out their forum. Instead of looking at another template system which would just confuse you, I'd think it'd make more sense to read about the one you're using...
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.