News:

Support the VirtueMart project and become a member

Main Menu

Language Portuguese Brazil

Started by sdinizr, August 05, 2016, 16:26:03 PM

Previous topic - Next topic

sdinizr

When I set Portuguese(Brazil) as default language for the site the following error messages appear in the site:
(Joomla version 2.5.28 Virtuemart version 3.0.14)

( ! ) Notice: Undefined index: pt-BR in C:\wamp\www\lisergourmet\administrator\components\com_virtuemart\helpers\config.php on line 948
Call Stack
#   Time   Memory   Function   Location
1   0.0020   140528   {main}( )   ..\index.php:0
2   0.3190   3181672   JSite->dispatch( )   ..\index.php:42
3   0.3430   3397424   JComponentHelper::renderComponent( )   ..\application.php:194
4   0.3620   3503040   JComponentHelper::executeComponent( )   ..\helper.php:348
5   0.3640   3552840   require_once( 'C:\wamp\www\lisergourmet\components\com_virtuemart\virtuemart.php' )   ..\helper.php:380
6   0.3920   4436328   VmConfig::loadConfig( )   ..\virtuemart.php:24
7   0.4890   5213432   VmConfig::setdbLanguageTag( )   ..\config.php:883

( ! ) Notice: Trying to get property of non-object in C:\wamp\www\lisergourmet\administrator\components\com_virtuemart\helpers\config.php on line 948
Call Stack
#   Time   Memory   Function   Location
1   0.0020   140528   {main}( )   ..\index.php:0
2   0.3190   3181672   JSite->dispatch( )   ..\index.php:42
3   0.3430   3397424   JComponentHelper::renderComponent( )   ..\application.php:194
4   0.3620   3503040   JComponentHelper::executeComponent( )   ..\helper.php:348
5   0.3640   3552840   require_once( 'C:\wamp\www\lisergourmet\components\com_virtuemart\virtuemart.php' )   ..\helper.php:380
6   0.3920   4436328   VmConfig::loadConfig( )   ..\virtuemart.php:24
7   0.4890   5213432   VmConfig::setdbLanguageTag( )   ..\config.php:883

How can i solve this problem?
Thank you.

GJC Web Design

a bit odd as the code is

if (class_exists('JLanguageHelper') && (method_exists('JLanguageHelper', 'getLanguages'))) {
         $languages = JLanguageHelper::getLanguages('lang_code');
         $ltag = JFactory::getLanguage()->getTag();
         self::$vmlangSef = $languages[$ltag]->sef;
         self::$jLangCount = count($languages);
      }

so this  --  $ltag = JFactory::getLanguage()->getTag();

is returning nothing

have you configured correctly the whole language setup in Joomla as well as in VM?  incl. config under   /administrator/index.php?option=com_languages&view=languages
(content languages)
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation