D
D
Den Savi2016-04-04 10:37:11
opencart
Den Savi, 2016-04-04 10:37:11

Error with displaying language in opencart. How to fix?

When I add to the header <?php echo $language; ?>, an error appears on the main page of the site:
Notice: Undefined variable: language in /home/masgr1/site.ru/www/catalog/view/theme/default/template/common/header.tpl on line 431
how to fix it?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
Ivan Goncharenko, 2016-04-04
@den_savi

it reads "The variable is unknown to me". The solution is to look for the presence of a variable in the controller. In the header.php controller (main page - site/public_html/catalog/controller/header.php) of one of my sites, I don't see the presence of such a variable. There is no such variable in the default version. Announce.
Such a variable exists in the language module. If you declare this variable language outside of the module, and even on the main page, you will be disappointed.
PS status pleased the guys from my department))) respect!

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question