I need to create product description with mass action. But dot symbol is break
- progreccor
-
Topic Author
- Offline
- SEO, webdesign
Less
More
5 years 8 months ago #328656
by progreccor
Я не явлюсь официальной службой поддержки!
Я здесь добровольно!
Хочешь получить купон на скидку Hikashop? Спроси меня как!
I need to create product description with mass action. But dot symbol is break was created by progreccor
-- HikaShop version -- : 4.4.0
-- Joomla version -- : 3.9.24
I try to create mass action that create product description with combination of static text and product name.
Some kind of:
concat('Great pizza of Moscow. Here is ', product.product_name, ' you get the best!')
But I get error message that table is not found. The problem with dot symbol.
What should I do?
-- Joomla version -- : 3.9.24
I try to create mass action that create product description with combination of static text and product name.
Some kind of:
concat('Great pizza of Moscow. Here is ', product.product_name, ' you get the best!')
But I get error message that table is not found. The problem with dot symbol.
What should I do?
Я не явлюсь официальной службой поддержки!
Я здесь добровольно!
Хочешь получить купон на скидку Hikashop? Спроси меня как!
Please Log in or Create an account to join the conversation.
5 years 7 months ago #328667
by nicolas
Replied by nicolas on topic I need to create product description with mass action. But dot symbol is break
Hi,
Yes, the dot is used as a separator for the table name and the column name in operations.
So there is a mechanism to retrieve them in order to add joins to the tables if necessary.
Add the line:
$entry = preg_replace('/\'(.*)\'/U', '', $entry);
before the line:
$data = explode('.',$entry);
in the file administrator/components/com_hikashop/classes/massaction.php and it should fix the problem.
Another solution is to use
instead of a dot since the description is HTML code.
Yes, the dot is used as a separator for the table name and the column name in operations.
So there is a mechanism to retrieve them in order to add joins to the tables if necessary.
Add the line:
$entry = preg_replace('/\'(.*)\'/U', '', $entry);
before the line:
$data = explode('.',$entry);
in the file administrator/components/com_hikashop/classes/massaction.php and it should fix the problem.
Another solution is to use
Code:
˙
Please Log in or Create an account to join the conversation.
- progreccor
-
Topic Author
- Offline
- SEO, webdesign
5 years 7 months ago #328698
by progreccor
Я не явлюсь официальной службой поддержки!
Я здесь добровольно!
Хочешь получить купон на скидку Hikashop? Спроси меня как!
Replied by progreccor on topic I need to create product description with mass action. But dot symbol is break
do you include this solution to next release of hikashop?
I don't want to hack the code...
I don't want to hack the code...
Я не явлюсь официальной службой поддержки!
Я здесь добровольно!
Хочешь получить купон на скидку Hikashop? Спроси меня как!
Please Log in or Create an account to join the conversation.
- progreccor
-
Topic Author
- Offline
- SEO, webdesign
5 years 7 months ago - 5 years 7 months ago #328706
by progreccor
is an upper dot - not usual dot
here it is - ˙
Я не явлюсь официальной службой поддержки!
Я здесь добровольно!
Хочешь получить купон на скидку Hikashop? Спроси меня как!
Replied by progreccor on topic I need to create product description with mass action. But dot symbol is break
Code:
˙
here it is - ˙
Я не явлюсь официальной службой поддержки!
Я здесь добровольно!
Хочешь получить купон на скидку Hikashop? Спроси меня как!
Last edit: 5 years 7 months ago by progreccor.
Please Log in or Create an account to join the conversation.
- progreccor
-
Topic Author
- Offline
- SEO, webdesign
5 years 7 months ago - 5 years 7 months ago #328712
by progreccor
Я не явлюсь официальной службой поддержки!
Я здесь добровольно!
Хочешь получить купон на скидку Hikashop? Спроси меня как!
Replied by progreccor on topic I need to create product description with mass action. But dot symbol is break
I have added this code:
but it doesn't help
still get error message
here is the sample for concat
Code:
foreach($entries as $entry){
$entry = preg_replace('/\'(.*)\'/U', '', $entry);
$data = explode('.',$entry);
if(!isset($data[1]) || (is_numeric($data[0]) && is_numeric($data[1])))
continue;
$strings[]['table'] = $data[0];
$strings[]['column'] = $data[1];
}
still get error message
here is the sample for concat
Code:
concat('Хотите заказать пиццу с доставкой в Ульяновске? Предлагаем заказать пиццу ', product_name, ' на сайте oran-g.ru ☎️ 8 800 300-66-03 Только Моцарелла! Только итальянский пицца-соус из мякоти томатов! Никаких кетчупов и майонезов. Быстрая доставка пиццы', product_name)
Я не явлюсь официальной службой поддержки!
Я здесь добровольно!
Хочешь получить купон на скидку Hikashop? Спроси меня как!
Last edit: 5 years 7 months ago by progreccor.
Please Log in or Create an account to join the conversation.
5 years 7 months ago #328714
by nicolas
Replied by nicolas on topic I need to create product description with mass action. But dot symbol is break
Hi,
I see. That's because of the dashes in your strings which splits the strings before and thus makes my modification not do anything.
Alright then, revert back the change, and instead, change the code:
to:
in that same file and it should work fine.
I see. That's because of the dashes in your strings which splits the strings before and thus makes my modification not do anything.
Alright then, revert back the change, and instead, change the code:
Code:
$string = str_replace($symbols,'||',$action['value']);
Code:
$string = preg_replace('/\'(.*)\'/U', '', $action['value']);
$string = str_replace($symbols,'||',$string);
The following user(s) said Thank You: progreccor
Please Log in or Create an account to join the conversation.
- progreccor
-
Topic Author
- Offline
- SEO, webdesign
5 years 7 months ago #328919
by progreccor
Я не явлюсь официальной службой поддержки!
Я здесь добровольно!
Хочешь получить купон на скидку Hikashop? Спроси меня как!
Replied by progreccor on topic I need to create product description with mass action. But dot symbol is break
yes, this solution really help me.
Do you include this patch to next version of hikashop?
Do you include this patch to next version of hikashop?
Я не явлюсь официальной службой поддержки!
Я здесь добровольно!
Хочешь получить купон на скидку Hikashop? Спроси меня как!
Please Log in or Create an account to join the conversation.
Less
More
- Posts: 12953
- Thank you received: 1778
5 years 7 months ago #328966
by Mohamed Thelji
Replied by Mohamed Thelji on topic I need to create product description with mass action. But dot symbol is break
Hello,
Of course that patch will be include through next Hikashop versions.
Kind regards,
Mohamed.
Of course that patch will be include through next Hikashop versions.
Kind regards,
Mohamed.
Please Log in or Create an account to join the conversation.
Time to create page: 0.364 seconds