*

Alex_PY

  • ***
  • 59 posts
Hi!

Two problems were found:
Both problems in file: item_pay.php

My site has 4 languages installed, the main one is English + 3 translation files into German, Spanish and Russian

1 problem is misspelling in a word "bellow". 
Because of it, there is no correct translation of the phrase into another language. The phrase in this file does not match the phrase in the languages files .po - .mo




2 - main problem:
 Impossible to make a payment with Cyrillic characters (immediately after creating an ad)

The phrase that causes the transfer of the ad promotion from WALLET payment to the cart to fail is:
Pay fee %s for item %s
in file:
item_pay.php

if(osc_apply_filter('osp_itempay_payment_wallet', true) !== false) {
              osp_wallet_button(round($total, 2), sprintf(__('Pay fee %s for item %s', 'osclass_pay'), osp_format_price($total, 2), $item_id), '901x2x'.$item_id.'x'.round($total, 2), array('user' => @$user['pk_i_id'], 'itemid' => $item_id, 'email' => @$user['s_email'], 'amount' => round($total, 2)));
            }

* Please check the probability of this bug on other payment methods.

English link - works correct
https://example.com/payments/wallet/3.36/user,20%7Citemid,23%7Cemail,[email protected]%7Camount,3.36%7Cconcept,Pay%20fee%203%20PYG%20for%20item%2023%7Cproduct,901x2x23x3.36%7C/Pay%20fee%203%20PYG%20for%20item%2023

Cyrillic characters - when site trying to transfer data to the basket - an error 404 is issued:
https://example.com/payments/wallet/3.36/user,20%7Citemid,23%7Cemail,[email protected]%7Camount,3.36%7Cconcept,%D0%9E%D0%BF%D0%BB%D0%B0%D1%82%D0%B0%203%20PYG%20%D0%B7%D0%B0%20%D0%BE%D0%B1%D1%8A%D1%8F%D0%B2%D0%BB%D0%B5%D0%BD%D0%B8%D0%B5%20#23|product,901x2x23x3.36|/%D0%9E%D0%BF%D0%BB%D0%B0%D1%82%D0%B0%203%20PYG%20%D0%B7%D0%B0%20%D0%BE%D0%B1%D1%8A%D1%8F%D0%B2%D0%BB%D0%B5%D0%BD%D0%B8%D0%B5%20#23


Spanish symbols - ok
https://example.com/payments/wallet/3.36/user,20%7Citemid,23%7Cemail,[email protected]%7Camount,3.36%7Cconcept,Pagar%20tasas%203%20PYG%20por%20art%C3%ADculo%2023%7Cproduct,901x2x23x3.36%7C/Pagar%20tasas%203%20PYG%20por%20art%C3%ADculo%2023

German symbols - ok
https://example.com/payments/wallet/3.36/user,20%7Citemid,23%7Cemail,[email protected]%7Camount,3.36%7Cconcept,Geb%C3%BChr%203%20PYG%20f%C3%BCr%20Artikel%2023%20zahlen%7Cproduct,901x2x23x3.36%7C/Geb%C3%BChr%203%20PYG%20f%C3%BCr%20Artikel%2023%20zahlen

Test phrases for po/mo files:

(en) Pay fee %s for item %s
(ru) Оплата %s за объявление #%s
(es) Pagar tasas %s por artículo %s
(de) Gebühr %s für Artikel %s zahlen

Please help me to solve this problem

Regards, Alex.

*

Alex_PY

  • ***
  • 59 posts
The second problem was solved after removing the # sign from the translation. :)

(ru) Оплата %s за объявление #%s

*

MB Themes

1) there can be even belllow and you still can translate it to whatever you want, or?
2) really weird as text is url encoded so this should really not happen, need to find simple way to reproduce
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

Alex_PY

  • ***
  • 59 posts
Re: Impossible to make a payment with # characters (after creating an ad)
« Reply #3 on: January 04, 2023, 09:26:50 PM »
In the first problem - with a typo:
I had to edit the file *.po so that this word was also in it with an error (bellow). Then the site engine sees both words equally and translates this phrase.

In the second problem - if I use the # symbol in the translation
for example, to indicate the
"ad number #%s"
ad nuber #21 (as a result)
 - then the url address is generated incorrectly, and I get a 404 error.
I just had this problem initially in the translation into Cyrillic (when I added # to the translation), and I mistakenly concluded that the problem was in the use of Cyrillic characters.
Here is the phrase where the error occurred:
(ru) Оплата %s за объявление #%s
(original) Pay fee %s for item %s
« Last Edit: January 04, 2023, 09:30:58 PM by Alex_PY »