xertog Posted December 11, 2015 Share Posted December 11, 2015 Hi, I want to make use of the new advanced slider orderform template. The products in a certain product category can have a true/false value for a feature. I would like to show this with an x or v symbol (fontaweome). Currently the advanced slider does not see a difference between these two values, which is logical to mee because they are both text strings. Does anyone in the community have experiences with TRUE/FALSE or YES/NO values other dan boolean (0/1) for comparison? 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted December 12, 2015 Share Posted December 12, 2015 as a basic example, if you wanted to replace a '0' feature value with a font awesome X, you could modify the following line in universalslider/products.tpl <span>{$value}</span> and change it to... <span>{if $value eq "0"}<i class="fa fa-times"></i>{else}{$value}{/if}</span> if you wanted to use TRUE and FALSE, you could use the following line... <span>{if $value eq "FALSE"}<i class="fa fa-times"></i>{elseif $value eq "TRUE"}<i class="fa fa-check"></i>{else}{$value}{/if}</span> that will show a cross for FALSE, a tick for TRUE or if neither, show the value. 0 Quote Link to comment Share on other sites More sharing options...
xertog Posted December 13, 2015 Author Share Posted December 13, 2015 Hi Brian, Thanks for your quick response. I was initially aiming for a solution without customizing the universal slider template but your posted solution should do the job and I will go for that route by creating a new order template based on the universal slider. - - - Updated - - - The reason why I would like to replace the 0 and 1 is to benefit from the progress bar which needs an integer in the value to work correctly. For the customer I want to represent true false with nice icons. The posted solution from Brian is a proper solution. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.