Author Topic: Additional strings for <LANG>.com_virtuemart.sef.ini  (Read 958 times)

arcturus

  • Jr. Member
  • **
  • Posts: 111
  • VirtueMart Version: 3.6.10 10211
Additional strings for <LANG>.com_virtuemart.sef.ini
« on: September 10, 2019, 15:22:25 pm »
Hello,

I discovered that there are some SEF parts that can also be defined, and they are translated automatically.

The following strings can be added to the <LANG>.com_virtuemart.sef.ini files for all the languages used:
Code: [Select]
COM_VIRTUEMART_SEF_NOTIFY="notify-me"
COM_VIRTUEMART_SEF_RECOMMEND="recommend-to-a-friend"
Cheers,
George
https://www.proxima-mundi.ro

Now I'm using Joomla! 3.9.15 and VM 3.6.10 10211 on PHP 7.3.9

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 10094
  • VM3.2 Cached and Optimized
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: Additional strings for <LANG>.com_virtuemart.sef.ini
« Reply #1 on: September 11, 2019, 12:39:42 pm »
thx, added them.
I should fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

arcturus

  • Jr. Member
  • **
  • Posts: 111
  • VirtueMart Version: 3.6.10 10211
Re: Additional strings for <LANG>.com_virtuemart.sef.ini
« Reply #2 on: September 12, 2019, 16:51:27 pm »
I also found a way to translate the 'number' string:

1. add
COM_VIRTUEMART_SEF_NUMBER="number/numero etc."
to  <LANG>.com_virtuemart.sef.ini
2. in /components/Com_virtuemart/router.php
on line 347 change
Code: [Select]
$segments[] = 'number/'.$query['order_number'];for
Code: [Select]
$segments[] = $helper->lang('number').'/'.$query['order_number'];also change line 568:
Code: [Select]
if ($segments[0] =='number')for
Code: [Select]
if ($segments[0] == $helper->lang('number'))

The same can be applied for 'id':
1. add
COM_VIRTUEMART_SEF_ID="id/whatever"
to  <LANG>.com_virtuemart.sef.ini
on line 350 change
Code: [Select]
$segments[] = 'id/'.$query['virtuemart_order_id'];for
Code: [Select]
$segments[] = $helper->lang('id').'/'.$query['virtuemart_order_id'];['order_number'];
Cheers,
George
https://www.proxima-mundi.ro

Now I'm using Joomla! 3.9.15 and VM 3.6.10 10211 on PHP 7.3.9

arcturus

  • Jr. Member
  • **
  • Posts: 111
  • VirtueMart Version: 3.6.10 10211
Re: Additional strings for <LANG>.com_virtuemart.sef.ini
« Reply #3 on: September 22, 2019, 14:17:32 pm »
It also works for orderdone string.
Just add
Code: [Select]
COM_VIRTUEMART_SEF_ORDERDONE="order-sent"in <LANG>.com_virtuemart.sef.ini
Cheers,
George
https://www.proxima-mundi.ro

Now I'm using Joomla! 3.9.15 and VM 3.6.10 10211 on PHP 7.3.9