Big Spender Posted September 18, 2014 Share Posted September 18, 2014 Just so anyone using the Crosshatch stock skin is aware: - If the 5 star rating on a product ends up being half a star then the first stars don't light up. Fine on all the other stock skins. Quote Link to comment Share on other sites More sharing options...
bsmither Posted September 18, 2014 Share Posted September 18, 2014 Please make these edits in the Crosshatch template file content.product.php: Was: {if $PRODUCT.review_score && $CTRL_REVIEW} <div class="rating"> {for $i = 1; $i < 5; $i++} {if $product.review_score>= $i} <img src="{$STORE_URL}/skins/{$SKIN_FOLDER}/images/star.png" alt="" /> {elseif $PRODUCT.review_score > ($i - 1) && $PRODUCT.review_score < $i} <img src="{$STORE_URL}/skins/{$SKIN_FOLDER}/images/star_half.png" alt="" /> {else} <img src="{$STORE_URL}/skins/{$SKIN_FOLDER}/images/star_off.png" alt="" /> {/if} {/for} </div> Now: {if $PRODUCT.review_score && $CTRL_REVIEW} <div class="rating"> {for $i=1 to 5} {if $PRODUCT.review_score gte $i} <img src="{$STORE_URL}/skins/{$SKIN_FOLDER}/images/star.png" alt="" /> {elseif $PRODUCT.review_score gt ($i - 1) && $PRODUCT.review_score lt $i} <img src="{$STORE_URL}/skins/{$SKIN_FOLDER}/images/star_half.png" alt="" /> {else} <img src="{$STORE_URL}/skins/{$SKIN_FOLDER}/images/star_off.png" alt="" /> {/if} {/for} </div> The second {if} has the wrong case for PRODUCT. Also, there are a few tweaks that use Smarty commands and syntax better. 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.