Easy solution for cafe or restaurant site
CafeEngine BuyNow!
v2.3 - $115

3 month of free 24/7 email support for buyers.

Developer manual: Creating new theme

Themes would be located in folder in /templates/ folder. Name of such folder will became a name of theme in admin area(see Settings->Site->Theme). Smarty templates of the theme would be located in /templates/<Theme name>/tpl folder. Other files such as images, styles, flash, scripts etc would be located in /templates/<Theme name>/. Addresses of these files would be written in templates as

templates/{$options.theme|escape:'url'}/<file name>

Each PHP file at front-side define 2 variables: $maintemplate and $tpl. $maintemplate points which container template would be used (it's "template.tpl" everywhere now) $tpl is a name of template file that would be used to generate content part of the page. Template with name $tpl.".tpl" will be included to container template. These variables allow you to have few completely different designs for any kind of pages. For example, if you'll replace line

$maintemplate="template.tpl";
in index.php to
$maintemplate=($_GET['id']=='1')?"main_page.tpl":"template.tpl";
you'll use main_page.tpl as a container template for home page.
Here is example that produce different content layout for menues that allow to order from the list and no:
if(empty($m["list_order"])) {
    $tpl="dish_list";
} else {
    $tpl="dish_list_order";
}

Here is a list of all existing templates and where its used:
Template Purpose Usage
template.tpl Container used on all pages. All other templates will be included to. All excluding show_photo.php
billing.tpl Billing page billing.php
calendar.tpl Events page events.php
checkout.tpl Checkout page checkout.php
contact.tpl Contact us page contact.php
dish_list.tpl Menu or menu section pages used for menues that has no quantity field for each meal, but has links to meals pages. ("Allow order from list" is "No"). menu.php
dish_list_order.tpl Menu or menu section pages used for menues that has quantity field for each meal and allow to add meals to order from list ("Allow order from list" is "Yes"). Supposed meals pages to be hidden. menu.php
dish_show.tpl Pages of meals dish.php
gb.tpl Guest book pages gb.php
map.tpl Google map page map.php
news.tpl News pages news.php
no_order.tpl Page with cafe/restaurant operating schedule. Supposed to be shown on order page when institution does not accept orders. order.php
order.tpl Order page order.php
page.tpl Custom site pages index.php
pcats.tpl List of sections of photo gallery photo.php
photos.tpl List of photos in section of photo gallery photo.php
review.tpl Pages with list of reviews review.php
review_form.tpl Add review form review.php
review_show.tpl Show review complete review.php
show_photo.tpl Show the photo with name and comment show_photo.php


Best Scripts on the Internet - Scripts.com™! Web Scripts Directory phpdirectory.com