hello!!
I have created an add-on that changes the value of the title $title
that is displayed when adding a product.
override.tpl could not change the value of $title
, post.tpl could change the value of $title
.
why???
Does anyone know why the behavior is known?
Also, do you know how I can change the $title value in override.tpl as well?
cs-cart
Multi-Vendorv4.15.2_JP_1
Target file
/design/backend/templates/views/products/update.tpl
{hook name="products:update_mainbox_params"}
{if $id}
{$title = $product_data.product|strip_tags}
{else}
{$title = __("new_product")}
{/if}
{/hook}
{include file="common/mainbox.tpl"
title=$title
content=$smarty.capture.mainbox
select_languages=(bool) $id
buttons=$smarty.capture.buttons
adv_buttons=$smarty.capture.adv_buttons
}
Addon file
/design/backend/templates/addons/products_settings_change/hooks/products/update_mainbox_params.override.tpl
{if $id}
{$title = $product_data.product|strip_tags}
{else}
{if $addons.products_settings_change.add_product_title_text}
{$title = $addons.products_settings_change.add_product_title_text}
{else}
{$title = __("new_product")}
{/if}
{/if}
{$title = $title scope="parent"}