Welcome Guest, Not a member yet? Register   Sign In
Library Cart is not support product in cyrillic
#1

[eluser]dimaomni[/eluser]
Hi all,

I cannot add item to cart in cyrillic (latin works fine).

I tried change in cart :

Code:
var $product_name_rules = '\p{Cyrillic}\x{0400}-\x{04FF}\.\:\-_ a-z0-9';
.....
if ( ! preg_match("/^[".$this->product_name_rules."]+$/iu", $items['name'], $b))

Also i tested in simple function
Code:
function test(){
// mb_regex_encoding('UTF-8');
   $product_name_rules = '\p{Cyrillic}\.\:\-_ a-z0-9';
   $items['name']= 'йяюэъ';
//  p{Cyrillic}
  $a = preg_match("/^[". $product_name_rules."]+$/iu", $items['name'], $matches);
var_dump($matches);

and it return true.

Why same condition is not work in Cart library ?

Thank you in advance!




Theme © iAndrew 2016 - Forum software by © MyBB