jdanthinne / advancedfeaturesvalues

Prestashop module to enable multiple values selection for features, and features values ordering.
GNU General Public License v2.0
38 stars 20 forks source link

Change the ',' Separator #23

Closed erfanmhd closed 8 years ago

erfanmhd commented 8 years ago

hi, i was wondering how can i change the comma separator? i want every feature value to be on a new line, i guess if i change the separator from "," to "
" i could do that.

can you give me a hint ?

jdanthinne commented 8 years ago

In override/classes/Product.php, search for SEPARATOR.

erfanmhd commented 8 years ago

Hi jdanthinne, thanks for reply, i've found this line product.php near line 53 and 69 and replaced the ", " with "_" but nothing happens at my frontend. i'm still gerring commas as separator.

SELECT name, GROUPCONCAT(value ORDER BY fv.position SEPARATOR "") AS value, pf.id_feature

jdanthinne commented 8 years ago

Did you change the file in the /modules/advancedfeaturesvalues/override/ or in /override/ directly? The second option is the good one. And you should use "
" instead of "_" I think.

erfanmhd commented 8 years ago

ive changed the file from /modules/advancedfeaturesvalues/override/ it doesn't matter what i put in there az separator < br > or - it doesn't changes the commas !

jdanthinne commented 8 years ago

In fact, Prestashop copy the module's override folder into the root /override folder of your server. You should change the files in this particular folder in order to make it work for you.

toyoted commented 8 years ago

I see modification made in override in my front office BUT i would like to make a new line for each feature but the "<br>" separator doesn't work properly (In front office it writes "<br>" instead of a new line)

SELECT name, GROUP_CONCAT(value ORDER BY fv.position SEPARATOR "<br>") AS value, pf.id_feature