View Issue Details

IDProjectCategoryView StatusLast Update
0001867OXID eShop (all versions)4.06. Language and translationspublic2010-06-19 15:38
ReporterFirefax Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionwon't fix 
Product Version4.3.2 revision 27884 
Summary0001867: Custom Theme and cust_lang.php not working without a lang.php
DescriptionHi,
I just changed my out/baisc/tpl/ theme-folder to the template override system. I did not move the lang.php to my customtheme folder (because it is the original one), only the cust_lang.php (where all my language changes are made) is in the customtheme folder now.

The shop ignores my cust_lang.php in the custom theme folder. It takes the language text from the original /basic/ folder. When i now copy the lang.php to my custom theme folder, everything works, including the cust_lang.php.

At the moment, I think you use a doulbe override system with a little hole in it. Maybe you can fix this or you should explain this behaviour in the manual.

CYA
Additional InformationI think, when the system checks the override of the lang.php, it doesn´t find one and falls back to the basic folder. Then it checks if there is an cust_lang.php in the basic folder and also doenst find this one.
The cust_lang.php file, which was changed according to the manual, will never be found by the shop.

Quick solution: Copy the lang.php to the custom theme dir.
TagsNo tags attached.
Theme
BrowserAll
PHP Versionany
Database Versionany

Activities

dainius.bigelis

2010-06-03 15:24

reporter   ~0003136

Reminder sent to: Firefax

Hi,

The behavior is as you described. The lang.php here is used to detect and scan whole directory for *_lang.php files ( like cust_lang.php).

Some solution from the source code side would be to scan all the dirs and return array of dirs, where lang.php or cust_lang.php are found. But such scanning would slow down the eshop performance.

So we will describe this behavior in documentation and it will be appended with requirement that lang.php file must be included in the custom theme dirs.

As a workaround to handle that more convenient way - you can create lang.php n custom them dir, which includes lang.php from /basic dir.

Sorry for incoveniences.
Best regards,

dainius.bigelis

2010-06-03 15:28

reporter   ~0003137

The documentation will be appended with correct behavior description and requirements for lang.php file. Thus entry here is closed.

dainius.bigelis

2010-06-19 15:38

reporter   ~0003210

Please check here for more details:
http://wiki.oxidforge.org/Tutorials/How_template_hierarchy_and_override_system_works