D
D
Denis Balandin2019-12-04 10:18:49
linux
Denis Balandin, 2019-12-04 10:18:49

How do I replace the "Add to Cart" button for a specific brand?

Hello Toaster!
Help, I'm writing a plugin now.
It is necessary that the “Add to Cart” button for the products of a certain brand should be changed.
I found how to actually replace the button, but I need some kind of condition to replace it only for products of a certain brand. Worth the pw-brands plugin.
Tell me ideas, or pieces of code?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
N
none7, 2018-12-22
@t3g1ng

sh is not bash! This error is being thrown by sh or possibly an older version of bash. if [ $ver = "Debian7" ];

A
aol-nnov, 2018-12-21
@aol-nnov

[ $
there may not be a gap by chance, but some kind of garbage, for example. it is necessary to clarify this
even if the variable, suddenly, turns out to be not defined, then it is better if
https://www.tldp.org/LDP/abs/html/

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question