Справочник функций

Ваш аккаунт

Войти через: 
Забыли пароль?
Регистрация
Информацию о новых материалах можно получать и без регистрации:

Почтовая рассылка

Подписчиков: -1
Последний выпуск: 19.06.2015

Проблема со Smarty

88K
14 декабря 2014 года
Fuhrick
3 / / 13.12.2014
Здравствуйте, я только учусь создавать сайты на php и у меня возникла ошибка с которой бьюсь не первый час, помогите пожалуйста.
Ошибка:
Цитата:
Fatal error: Uncaught --> Smarty: Unable to load template file 'product.tpl' in 'store_front.tpl' <-- thrown in C:tshirtshoplibssmartysyspluginssmarty_internal_templatebase.php on line 129


кусок кода возле 129 строчки:

Цитата:
// must reset merge template date
$_template->smarty->merged_templates_func = array();
// get rendered template
// disable caching for evaluated code
if ($_template->source->recompiled) {
$_template->caching = false;
}
// checks if template exists
if (!$_template->source->exists) {
if ($_template->parent instanceof Smarty_Internal_Template) {
$parent_resource = " in '{$_template->parent->template_resource}'";
} else {
$parent_resource = '';
}
throw new SmartyException("Unable to load template {$_template->source->type} '{$_template->source->name}'{$parent_resource}");(129ая)
}
// read from cache or render
if (!($_template->caching == Smarty::CACHING_LIFETIME_CURRENT || $_template->caching == Smarty::CACHING_LIFETIME_SAVED) || !$_template->cached->valid) {
// render template (not loaded and not in cache)
if (!$_template->source->uncompiled) {
/** @var Smarty_Internal_Template $_smarty_tpl
* used in evaluated code
*/


код product.tpl

Цитата:
{load_presentation_object filename="product" assign="obj"}
<h1 class="title">{$obj->mProduct.name}</h1>
{if $obj->mProduct.image}
<img class="product-image" src="{$obj->mProduct.image}"
alt="{$obj->mProduct.name} image" />
{/if}
{if $obj->mProduct.image_2}
<img class="product-image" src="{$obj->mProduct.image_2}"
alt="{$obj->mProduct.name} image 2" />
{/if}
<p class="description">{$obj->mProduct.description}</p>
<p class="section">
Price:
{if $obj->mProduct.discounted_price != 0}
<span class="old-price">{$obj->mProduct.price}</span>
<span class="price">{$obj->mProduct.discounted_price}</span>
{else}
<span class="price">{$obj->mProduct.price}</span>
{/if}
</p>
{if $obj->mLinkToContinueShopping}
<a href="{$obj->mLinkToContinueShopping}">Continue Shopping</a>
{/if}
<h2>Find similar products in our catalog:</h2>
<ol>
{section name=i loop=$obj->mLocations}
<li class="navigation">
{strip}
<a href="{$obj->mLocations.link_to_department}">
{$obj->mLocations.department_name}
</a>
{/strip}
&raquo;
{strip}
<a href="{$obj->mLocations.link_to_category}">
{$obj->mLocations.category_name}
</a>
{/strip}
</li>
{/section}
</ol>


Спасибо заранее.

Реклама на сайте | Обмен ссылками | Ссылки | Экспорт (RSS) | Контакты
Добавить статью | Добавить исходник | Добавить хостинг-провайдера | Добавить сайт в каталог