What Is A Feature Code And Why Isn't It In $Features Object?

So I'm trying to access a Brand/Mfg feature in a sane way to make a trigger for some logic. I see there is a "feature code" available in backend. There is no information about this anywhere in docs though.

What does it do? What is it for? Why isn't it available in $features object/array at say, design/themes/*/templates/views/products/components/product_features_short_list.tpl?

Im asking this because, when brand is available, the features area at the top of a product page redirects into the parent category with brand filter selected, instead into the full results of the brand page itself. There needs to be an additional IF to account for this, and that IF needs some kinda sane trigger besides a feature id or language string name.

Thanks.

So I'm trying to access a Brand/Mfg feature in a sane way to make a trigger for some logic. I see there is a "feature code" available in backend. There is no information about this anywhere in docs though.

What does it do? What is it for? Why isn't it available in $features object/array at say, design/themes/*/templates/views/products/components/product_features_short_list.tpl?

Im asking this because, when brand is available, the features area at the top of a product page redirects into the parent category with brand filter selected, instead into the full results of the brand page itself. There needs to be an additional IF to account for this, and that IF needs some kinda sane trigger besides a feature id or language string name.

Thanks.

Feature code is similar to product code. it is used to identify the product feature. We have also made a search over the files and found that at the moment this code is used only by the YML Export module which is a part of the CS-Cart Russian Build

Ah cool, thanks I thought I was crazy (didn't see it in store at all). I will work on making it available in the build we have too.

Is there an object/array dump/trace func already in CS for debug besides the GUI? Right now we use this https://gist.github.com/dhaupin/d9d48328dbe312f6c0de(even smarty side since their debug_print_var is junk). Wasn't sure if there was something more robust in the CS debug/error/exception handler that could be used instead. I dont like the debug mode GUI, it's too heavy and slow, and can't be used on a production store running since anyone can see it.

Note: if anyone needs dumps on production TPL's, are behind minifier which removes comments, and you can't exit(), try this with the above x_r():


Thanks.

Is there an object/array dump/trace func already in CS for debug besides the GUI? Right now we use this https://gist.github.com/dhaupin/d9d48328dbe312f6c0de(even smarty side since their debug_print_var is junk). Wasn't sure if there was something more robust in the CS debug/error/exception handler that could be used instead. I dont like the debug mode GUI, it's too heavy and slow, and can't be used on a production store running since anyone can see it.

To debug code please use fn_print_r or fn_print_die functions

PHP

fn_print_r($data);

JS

fn_print_r($data);

TPL

{$data|fn_print_r}

Ah cool, thanks I thought I was crazy (didn't see it in store at all). I will work on making it available in the build we have too.

Is there an object/array dump/trace func already in CS for debug besides the GUI? Right now we use this https://gist.github.com/dhaupin/d9d48328dbe312f6c0de(even smarty side since their debug_print_var is junk). Wasn't sure if there was something more robust in the CS debug/error/exception handler that could be used instead. I dont like the debug mode GUI, it's too heavy and slow, and can't be used on a production store running since anyone can see it.

Note: if anyone needs dumps on production TPL's, are behind minifier which removes comments, and you can't exit(), try this with the above x_r():

 
Thanks.

This should help: http://docs.cs-cart.com/4.3.x/developer_guide/getting_started/debugging.html